/* ==========================================================================
   Shadowrocket Help - Nordic Glacier & Forest Teal Theme (北欧冰川森林薄荷风格)
   Designed for Distinctive Visual Identity & Top-tier Bing SEO Performance
   ========================================================================== */

:root {
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", sans-serif;
  --font-mono: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, "Liberation Mono", "Courier New", monospace;

  /* Theme Palette - Glacier White & Forest Teal */
  --bg-page: #f4f6f8;
  --bg-surface: #ffffff;
  --bg-card: #ffffff;
  --bg-card-hover: #fcfdfe;
  --bg-card-subtle: #edf2f7;

  --color-primary: #0d9488;        /* Forest Teal 600 */
  --color-primary-hover: #0f766e;  /* Forest Teal 700 */
  --color-primary-light: rgba(13, 148, 136, 0.08);

  --color-accent: #14b8a6;         /* Mint Teal 500 */
  --color-success: #10b981;        /* Emerald 500 */
  --color-warning: #f59e0b;        /* Amber 500 */
  --color-danger: #ef4444;         /* Red 500 */

  --text-main: #0f172a;            /* Slate 900 */
  --text-muted: #475569;           /* Slate 600 */
  --text-dim: #94a3b8;             /* Slate 400 */

  --border-color: #e2e8f0;
  --border-hover: #cbd5e1;

  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.05);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06);
  --shadow-lg: 0 12px 28px rgba(0, 0, 0, 0.08);

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 16px;
  --radius-full: 9999px;

  --max-width: 1200px;
  --header-height: 72px;
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.65;
  color: var(--text-main);
  background-color: var(--bg-page);
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--header-height) + 24px);
  -webkit-text-size-adjust: 100%;
}

body {
  background-color: var(--bg-page);
  overflow-x: hidden;
}

a {
  color: var(--color-primary);
  text-decoration: none;
  transition: all 0.2s ease;
}

a:hover {
  color: var(--color-primary-hover);
}

.container {
  width: 100%;
  max-width: var(--max-width);
  margin-left: auto;
  margin-right: auto;
  padding-left: 20px;
  padding-right: 20px;
}

h1, h2, h3, h4 {
  color: var(--text-main);
  font-weight: 700;
  line-height: 1.28;
}

h1 {
  font-size: 2.7rem;
  letter-spacing: -0.02em;
}

h2 {
  font-size: 2.1rem;
  margin-bottom: 0.8rem;
}

h3 {
  font-size: 1.35rem;
  margin-bottom: 0.5rem;
}

p {
  color: var(--text-muted);
  margin-bottom: 1rem;
}

p:last-child {
  margin-bottom: 0;
}

/* Header & Nav */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border-color);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.brand-logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-size: 1.25rem;
  font-weight: 800;
  color: var(--text-main);
}

.brand-icon {
  width: 38px;
  height: 38px;
  background: linear-gradient(135deg, var(--color-primary), var(--color-accent));
  border-radius: var(--radius-md);
  display: flex;
  align-items: center;
  justify-content: center;
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.3);
}

.brand-badge {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: var(--radius-full);
  background: var(--color-primary-light);
  color: var(--color-primary);
  border: 1px solid rgba(13, 148, 136, 0.25);
}

.nav-menu {
  display: flex;
  align-items: center;
  gap: 20px;
  list-style: none;
}

.nav-link {
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 8px 12px;
  border-radius: var(--radius-sm);
  transition: all 0.2s ease;
}

.nav-link:hover, .nav-link.active {
  color: var(--color-primary);
  background: rgba(13, 148, 136, 0.06);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  padding: 10px 22px;
  border-radius: var(--radius-md);
  border: 1px solid transparent;
  cursor: pointer;
  transition: all 0.2s ease;
}

.btn-primary {
  background: var(--color-primary);
  color: #ffffff;
  box-shadow: 0 2px 8px rgba(13, 148, 136, 0.25);
}

.btn-primary:hover {
  background: var(--color-primary-hover);
  box-shadow: 0 4px 14px rgba(13, 148, 136, 0.35);
  transform: translateY(-1px);
  color: #ffffff;
}

.btn-secondary {
  background: #ffffff;
  color: var(--text-main);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: #f8fafc;
  border-color: var(--border-hover);
  color: var(--text-main);
}

.mobile-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-main);
  font-size: 1.5rem;
  cursor: pointer;
}

/* Hero Section */
.hero-section {
  padding: 80px 0 60px;
  position: relative;
  background: linear-gradient(180deg, #ffffff 0%, #f4f6f8 100%);
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 44px;
  align-items: center;
}

.hero-pill {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px;
  border-radius: var(--radius-full);
  background: #ffffff;
  border: 1px solid var(--border-color);
  color: var(--color-primary);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 24px;
  box-shadow: var(--shadow-sm);
}

.hero-pill .dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--color-success);
}

.hero-title .highlight-teal {
  color: var(--color-primary);
}

.hero-subtitle {
  font-size: 1.15rem;
  line-height: 1.75;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.hero-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  margin-bottom: 32px;
}

.hero-features-list {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  list-style: none;
  font-size: 0.9rem;
  color: var(--text-muted);
}

.hero-features-list li {
  display: flex;
  align-items: center;
  gap: 8px;
}

.hero-features-list svg {
  color: var(--color-primary);
}

/* Diagnostic Quick Widget */
.diagnostic-widget {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 26px;
  box-shadow: var(--shadow-md);
}

.widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding-bottom: 14px;
  margin-bottom: 16px;
  border-bottom: 1px solid var(--border-color);
}

.widget-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  background: #f8fafc;
  border-radius: var(--radius-md);
  margin-bottom: 10px;
  font-size: 0.875rem;
}

/* Sections */
.section {
  padding: 70px 0;
}

.section-alt {
  background: #ffffff;
  border-top: 1px solid var(--border-color);
  border-bottom: 1px solid var(--border-color);
}

.section-header {
  text-align: center;
  max-width: 800px;
  margin: 0 auto 52px;
}

.section-tag {
  display: inline-block;
  font-size: 0.825rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--color-primary);
  background: var(--color-primary-light);
  padding: 4px 14px;
  border-radius: var(--radius-full);
  margin-bottom: 14px;
}

.section-desc {
  font-size: 1.1rem;
  color: var(--text-muted);
}

/* Grids */
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 26px;
}

.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 30px;
}

.grid-4 {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
}

/* Cards */
.card-teal {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-lg);
  padding: 28px;
  transition: all 0.25s ease;
  position: relative;
  box-shadow: var(--shadow-sm);
}

.card-teal:hover {
  transform: translateY(-4px);
  border-color: var(--color-primary);
  box-shadow: var(--shadow-md);
}

.card-icon {
  width: 50px;
  height: 50px;
  border-radius: var(--radius-md);
  background: var(--color-primary-light);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 20px;
}

/* Table */
.table-box {
  overflow-x: auto;
  border-radius: var(--radius-lg);
  border: 1px solid var(--border-color);
  background: #ffffff;
  margin: 32px 0;
  box-shadow: var(--shadow-sm);
}

.styled-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.95rem;
}

.styled-table th {
  background: #f8fafc;
  padding: 16px 22px;
  color: var(--text-main);
  font-weight: 700;
  border-bottom: 1px solid var(--border-color);
}

.styled-table td {
  padding: 16px 22px;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-muted);
}

.styled-table tr:last-child td {
  border-bottom: none;
}

.styled-table tr:hover td {
  background: #f1f5f9;
}

.pill-badge {
  display: inline-block;
  padding: 3px 10px;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 700;
}

.pill-teal { background: rgba(13, 148, 136, 0.12); color: #0d9488; }
.pill-blue { background: rgba(59, 130, 246, 0.12); color: #2563eb; }
.pill-green { background: rgba(16, 185, 129, 0.12); color: #059669; }

/* Workflow Steps */
.step-item {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 24px;
  margin-bottom: 34px;
  padding-bottom: 34px;
  border-bottom: 1px dashed var(--border-color);
}

.step-item:last-child {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.step-number {
  width: 68px;
  height: 68px;
  border-radius: var(--radius-lg);
  background: #ffffff;
  border: 1px solid var(--border-color);
  color: var(--color-primary);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.6rem;
  font-weight: 800;
  font-family: var(--font-mono);
  box-shadow: var(--shadow-sm);
}

.step-content h3 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}

.step-tips {
  margin-top: 14px;
  padding: 14px 18px;
  background: #f8fafc;
  border-radius: var(--radius-md);
  font-size: 0.9rem;
  border-left: 3px solid var(--color-primary);
}

/* Callouts */
.callout {
  padding: 18px 22px;
  border-radius: var(--radius-md);
  margin: 24px 0;
  border-left: 4px solid;
  background: #ffffff;
  box-shadow: var(--shadow-sm);
}

.callout-teal {
  border-color: var(--color-primary);
  background: #f0fdfa;
}

.callout-amber {
  border-color: var(--color-warning);
  background: #fffbeb;
}

.callout-title {
  font-weight: 700;
  font-size: 1rem;
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 6px;
  color: var(--text-main);
}

/* FAQ Accordion */
.faq-list {
  max-width: 880px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.faq-card {
  background: #ffffff;
  border: 1px solid var(--border-color);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: all 0.2s ease;
  box-shadow: var(--shadow-sm);
}

.faq-card:hover {
  border-color: var(--border-hover);
}

.faq-header {
  width: 100%;
  padding: 20px 24px;
  background: none;
  border: none;
  text-align: left;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-main);
  display: flex;
  align-items: center;
  justify-content: space-between;
  cursor: pointer;
}

.faq-header:focus {
  outline: none;
  background: #f8fafc;
}

.faq-arrow {
  width: 22px;
  height: 22px;
  color: var(--text-dim);
  transition: transform 0.25s ease;
}

.faq-card.active .faq-arrow {
  transform: rotate(180deg);
  color: var(--color-primary);
}

.faq-body {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s cubic-bezier(0, 1, 0, 1);
  padding: 0 24px;
  color: var(--text-muted);
  font-size: 0.95rem;
}

.faq-card.active .faq-body {
  max-height: 1000px;
  transition: max-height 0.3s ease-in-out;
  padding: 0 24px 22px;
}

/* Footer */
.site-footer {
  background: #0f172a;
  color: #94a3b8;
  padding: 70px 0 30px;
  border-top: 1px solid #1e293b;
}

.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr repeat(3, 1fr);
  gap: 40px;
  margin-bottom: 50px;
}

.footer-disclaimer {
  background: #1e293b;
  border: 1px solid #334155;
  padding: 18px 22px;
  border-radius: var(--radius-md);
  margin-bottom: 36px;
  font-size: 0.825rem;
  line-height: 1.7;
  color: #cbd5e1;
}

.footer-col h4 {
  color: #ffffff;
  font-size: 1rem;
  margin-bottom: 20px;
}

.footer-links {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-links a {
  color: #94a3b8;
  font-size: 0.9rem;
}

.footer-links a:hover {
  color: #2dd4bf;
}

.footer-bottom {
  padding-top: 30px;
  border-top: 1px solid #1e293b;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.85rem;
  color: #64748b;
  flex-wrap: wrap;
  gap: 16px;
}

/* Responsive */
@media (max-width: 1024px) {
  .hero-grid {
    grid-template-columns: 1fr;
    gap: 36px;
  }
  .grid-3, .grid-4 {
    grid-template-columns: repeat(2, 1fr);
  }
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  h1 { font-size: 2.1rem; }
  h2 { font-size: 1.65rem; }
  .mobile-toggle { display: block; }
  .nav-menu {
    position: fixed;
    top: var(--header-height);
    left: 0;
    right: 0;
    background: #ffffff;
    flex-direction: column;
    align-items: flex-start;
    padding: 24px;
    border-bottom: 1px solid var(--border-color);
    box-shadow: var(--shadow-lg);
    display: none;
  }
  .nav-menu.open {
    display: flex;
  }
  .nav-link {
    width: 100%;
    padding: 12px 14px;
    font-size: 1rem;
  }
  .grid-2, .grid-3, .grid-4 {
    grid-template-columns: 1fr;
  }
  .step-item {
    grid-template-columns: 1fr;
    gap: 14px;
  }
  .step-number {
    width: 50px;
    height: 50px;
    font-size: 1.3rem;
  }
  .footer-grid {
    grid-template-columns: 1fr;
    gap: 32px;
  }
}
