/* ti-dai.com — first-pass static styles (no CDN) */
*,
*::before,
*::after {
  box-sizing: border-box;
}

:root {
  --bg: #f6f8fb;
  --surface: #ffffff;
  --text: #1a2332;
  --muted: #5b6b7c;
  --border: #e2e8f0;
  --brand: #0b6bcb;
  --brand-dark: #084a8f;
  --brand-soft: #e8f2fc;
  --accent: #0d9488;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 8px 24px rgba(16, 24, 40, 0.06);
  --max: 960px;
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Hiragino Sans GB", "Microsoft YaHei", "Noto Sans SC", sans-serif;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: var(--font);
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

a {
  color: var(--brand);
  text-decoration: none;
}

a:hover {
  color: var(--brand-dark);
  text-decoration: underline;
}

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

.container {
  width: min(100% - 2rem, var(--max));
  margin-inline: auto;
}

/* Header */
.site-header {
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 10;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.logo {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
  color: inherit;
  text-decoration: none;
}

.logo:hover {
  text-decoration: none;
  color: inherit;
}

.logo-cn {
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.02em;
}

.logo-en {
  font-size: 0.75rem;
  color: var(--muted);
  font-weight: 500;
}

.nav {
  display: flex;
  gap: 0.25rem;
  flex-wrap: wrap;
}

.nav a {
  color: var(--muted);
  padding: 0.4rem 0.7rem;
  border-radius: 8px;
  font-size: 0.95rem;
  text-decoration: none;
}

.nav a:hover,
.nav a[aria-current="page"] {
  color: var(--brand);
  background: var(--brand-soft);
  text-decoration: none;
}

/* Main */
main {
  flex: 1;
  padding: 2rem 0 3rem;
}

/* Hero */
.hero {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  padding: 2.25rem 1.75rem;
  text-align: center;
}

.hero h1 {
  margin: 0 0 0.6rem;
  font-size: clamp(1.6rem, 4vw, 2.1rem);
  line-height: 1.25;
}

.hero .tagline {
  margin: 0 auto 1.5rem;
  max-width: 36em;
  color: var(--muted);
  font-size: 1.05rem;
}

.badge {
  display: inline-block;
  margin-bottom: 0.9rem;
  padding: 0.25rem 0.65rem;
  font-size: 0.75rem;
  font-weight: 600;
  color: var(--brand);
  background: var(--brand-soft);
  border-radius: 999px;
}

/* Search */
.search-box {
  display: flex;
  gap: 0.5rem;
  max-width: 520px;
  margin: 0 auto;
  flex-wrap: wrap;
  justify-content: center;
}

.search-box input[type="search"] {
  flex: 1 1 240px;
  min-width: 0;
  padding: 0.75rem 1rem;
  border: 1px solid var(--border);
  border-radius: 10px;
  font: inherit;
  font-size: 1rem;
  background: #fff;
  color: var(--text);
}

.search-box input[type="search"]:focus {
  outline: 2px solid var(--brand);
  outline-offset: 1px;
  border-color: var(--brand);
}

.search-box button {
  padding: 0.75rem 1.25rem;
  border: none;
  border-radius: 10px;
  background: var(--brand);
  color: #fff;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.search-box button:hover {
  background: var(--brand-dark);
}

.search-hint {
  margin: 0.75rem 0 0;
  font-size: 0.85rem;
  color: var(--muted);
  min-height: 1.3em;
}

.search-hint.is-notice {
  color: var(--accent);
  font-weight: 500;
}

/* Features */
.section {
  margin-top: 2.25rem;
}

.section h2 {
  margin: 0 0 1rem;
  font-size: 1.25rem;
}

.features {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1rem;
}

.features-5 {
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
  box-shadow: var(--shadow);
}

.card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
}

.card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.card-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  margin-bottom: 0.65rem;
  border-radius: 8px;
  background: var(--brand-soft);
  color: var(--brand);
  font-weight: 700;
  font-size: 0.85rem;
}

/* Content pages */
.page-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  box-shadow: var(--shadow);
  padding: 2rem 1.75rem;
  max-width: 40rem;
}

.page-card h1 {
  margin: 0 0 1rem;
  font-size: 1.6rem;
}

.page-card p {
  margin: 0 0 1rem;
  color: var(--muted);
}

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

.page-card ul {
  margin: 0 0 1rem;
  padding-left: 1.25rem;
  color: var(--muted);
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
}

.contact-list li {
  margin-bottom: 0.75rem;
  padding: 0.85rem 1rem;
  background: var(--bg);
  border-radius: 10px;
  border: 1px solid var(--border);
}

.contact-list strong {
  display: block;
  color: var(--text);
  margin-bottom: 0.2rem;
}

.note {
  font-size: 0.9rem;
  color: var(--muted);
}

.note em {
  font-style: normal;
  color: #b45309;
  background: #fff7ed;
  padding: 0.1rem 0.35rem;
  border-radius: 4px;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  padding: 1.5rem 0;
  color: var(--muted);
  font-size: 0.875rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  justify-content: space-between;
  align-items: flex-start;
}

.footer-brand {
  font-weight: 600;
  color: var(--text);
}

.footer-links {
  display: flex;
  gap: 1rem;
  flex-wrap: wrap;
}

.footer-links a {
  color: var(--muted);
}

.building-note {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  width: 100%;
  font-size: 0.85rem;
}

/* 404 */
.center-msg {
  text-align: center;
  padding: 3rem 1rem;
}

.center-msg h1 {
  margin: 0 0 0.5rem;
}

@media (max-width: 560px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .hero {
    padding: 1.75rem 1.25rem;
  }

  .page-card {
    padding: 1.5rem 1.25rem;
  }
}

/* About / Contact content (ti-dai frame + fiberda facts) */
.page-wide {
  max-width: none;
}

.eyebrow {
  margin: 0 0 0.35rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--brand);
  text-transform: uppercase;
}

.lead {
  margin: 0 0 1.25rem;
  font-size: 1.05rem;
  color: var(--text);
  font-weight: 500;
}

.page-card .sec {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid var(--border);
}

.page-card .sec:first-of-type {
  border-top: 0;
  padding-top: 0;
}

.page-card .sec h2 {
  margin: 0 0 1rem;
  font-size: 1.25rem;
  color: var(--text);
}

.page-card .sec h3 {
  margin: 0 0 0.65rem;
  font-size: 1.05rem;
  color: var(--text);
}

.page-card .sec p {
  color: var(--muted);
}

.media-hero {
  margin: 0 0 1.5rem;
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border);
}

.media-hero img,
.sec-media img,
.img-grid img,
.office-card > img,
.prod-lines img,
.contact-band > img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: var(--bg);
}

.sec-media {
  margin: 0 0 1rem;
}

.img-grid {
  display: grid;
  gap: 0.75rem;
}

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

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

.prod-lines {
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 1.25rem;
  align-items: start;
}

.prod-lines p {
  margin: 0 0 0.85rem;
  font-size: 0.92rem;
}

.office-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.office-card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.office-card > img {
  border: 0;
  border-radius: 0;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.office-body {
  padding: 0.9rem 1rem 1rem;
}

.ct-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.ct-list li {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.4rem 0.75rem;
  padding: 0.35rem 0;
  border-bottom: 1px dashed var(--border);
  font-size: 0.9rem;
}

.ct-list li:last-child {
  border-bottom: 0;
}

.ct-k {
  color: var(--muted);
  font-weight: 600;
}

.ct-v {
  color: var(--text);
  word-break: break-word;
}

.contact-band {
  display: grid;
  grid-template-columns: 1.2fr 1fr;
  gap: 1.25rem;
  align-items: start;
}

.btn {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.55rem 1rem;
  border-radius: 8px;
  background: var(--brand);
  color: #fff !important;
  font-weight: 600;
  text-decoration: none !important;
}

.btn:hover {
  background: var(--brand-dark);
}

.footer-inner a {
  color: var(--brand);
}

@media (max-width: 800px) {
  .img-grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }

  .prod-lines,
  .contact-band {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 560px) {
  .img-grid-2 {
    grid-template-columns: 1fr;
  }

  .ct-list li {
    grid-template-columns: 1fr;
  }
}
