/* 蔡文胜 — editorial investor profile
   Palette: deep charcoal · electric teal · muted gold (Crypto+AI / HK finance) */

:root {
  --charcoal-950: #0b0e11;
  --charcoal-900: #12161c;
  --charcoal-800: #1a212b;
  --charcoal-700: #252e3a;
  --teal-500: #1ec8c1;
  --teal-400: #3dd9d2;
  --teal-300: #7ee8e3;
  --teal-glow: rgba(30, 200, 193, 0.16);
  --gold-500: #c9a227;
  --gold-400: #dbb84a;
  --gold-100: #f7f0d8;
  --slate-400: #8b96a5;
  --slate-300: #a8b2bf;
  --slate-200: #d2d8e0;
  --cream: #f4f2ec;
  --paper: #faf9f6;
  --text: #141920;
  --text-muted: #4a5563;
  --radius: 10px;
  --shadow: 0 16px 48px rgba(11, 14, 17, 0.1);
  --max: 1120px;
  --font: "Noto Sans TC", "Source Han Sans TC", "PingFang TC", "Microsoft JhengHei", system-ui, sans-serif;
  --font-display: "Noto Serif TC", "Source Han Serif TC", "Songti TC", Georgia, serif;
  --font-en: "Noto Sans", "Noto Sans TC", system-ui, sans-serif;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 4.75rem;
}

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.05rem;
  line-height: 1.75;
  color: var(--text);
  background: var(--cream);
  -webkit-font-smoothing: antialiased;
}

body.lang-en {
  font-family: var(--font-en);
}

img { max-width: 100%; display: block; }
a { color: #0d6e69; text-underline-offset: 0.18em; }
a:hover { color: var(--gold-500); }

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--teal-500);
  color: var(--charcoal-950);
  padding: 0.5rem 1rem;
  z-index: 100;
  font-weight: 600;
}
.skip-link:focus { left: 1rem; top: 1rem; }

/* —— Header —— */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 14, 17, 0.94);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid rgba(30, 200, 193, 0.12);
}

.header-inner {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.8rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.logo {
  display: flex;
  flex-direction: column;
  gap: 0.05rem;
  text-decoration: none;
  color: var(--paper);
  min-width: 0;
}
.logo-name {
  font-family: var(--font-display);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: 0.04em;
}
.logo-sub {
  font-size: 0.7rem;
  color: var(--teal-400);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid rgba(255,255,255,0.2);
  color: var(--paper);
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  cursor: pointer;
  font-size: 0.85rem;
}

.nav-wrap {
  display: flex;
  align-items: center;
  gap: 1.25rem;
}

.site-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 0.15rem 0.9rem;
  align-items: center;
}
.site-nav a {
  color: rgba(250, 249, 246, 0.78);
  text-decoration: none;
  font-size: 0.82rem;
  font-weight: 500;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.site-nav a:hover { color: var(--teal-400); }

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.35rem 0.7rem;
  border-radius: 999px;
  border: 1px solid rgba(30, 200, 193, 0.45);
  color: var(--teal-300);
  text-decoration: none;
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
}
.lang-toggle:hover {
  background: var(--teal-glow);
  color: var(--teal-400);
}

/* —— Hero —— */
.hero {
  position: relative;
  background:
    radial-gradient(ellipse 80% 60% at 85% 15%, rgba(30, 200, 193, 0.18), transparent 55%),
    radial-gradient(ellipse 50% 40% at 10% 80%, rgba(201, 162, 39, 0.1), transparent 50%),
    linear-gradient(165deg, var(--charcoal-950) 0%, var(--charcoal-900) 45%, var(--charcoal-800) 100%);
  color: var(--paper);
  padding: 4.5rem 1.25rem 4rem;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: auto 0 0 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, var(--teal-500), var(--gold-500), transparent);
  opacity: 0.5;
}

.hero-inner {
  max-width: var(--max);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr;
  gap: 2.5rem;
  align-items: end;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-400);
  margin-bottom: 1rem;
}
.eyebrow::before {
  content: "";
  width: 1.5rem;
  height: 2px;
  background: var(--gold-500);
}

.hero h1 {
  font-family: var(--font-display);
  font-size: clamp(2.4rem, 5vw, 3.6rem);
  font-weight: 700;
  line-height: 1.15;
  margin: 0 0 0.5rem;
  letter-spacing: 0.02em;
}
.hero-en-name {
  font-size: 1.15rem;
  color: var(--slate-300);
  margin: 0 0 1.25rem;
  font-weight: 400;
  letter-spacing: 0.04em;
}
.hero-lead {
  font-size: 1.08rem;
  color: rgba(250, 249, 246, 0.82);
  max-width: 36rem;
  margin: 0 0 1.75rem;
}

.role-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: 0;
  padding: 0;
  list-style: none;
}
.role-chips li {
  font-size: 0.8rem;
  padding: 0.4rem 0.75rem;
  border-radius: 6px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(30, 200, 193, 0.25);
  color: var(--teal-300);
}

.hero-aside {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 1.5rem 1.4rem;
  backdrop-filter: blur(8px);
}
.hero-aside h2 {
  font-size: 0.75rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--gold-400);
  margin: 0 0 1rem;
  font-weight: 700;
}
.fact-list {
  margin: 0;
  padding: 0;
  list-style: none;
}
.fact-list li {
  display: grid;
  grid-template-columns: 5.5rem 1fr;
  gap: 0.75rem;
  padding: 0.55rem 0;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  font-size: 0.92rem;
}
.fact-list li:last-child { border-bottom: 0; }
.fact-list dt,
.fact-list .k {
  color: var(--slate-400);
  font-size: 0.8rem;
}
.fact-list .v { color: var(--paper); }

.disclaimer-bar {
  max-width: var(--max);
  margin: 0 auto;
  padding: 0.85rem 1.25rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  background: var(--paper);
  border-bottom: 1px solid var(--slate-200);
}
.disclaimer-bar strong { color: var(--charcoal-800); }

/* —— Sections —— */
.section {
  padding: 3.75rem 1.25rem;
}
.section-alt { background: var(--paper); }
.section-dark {
  background: var(--charcoal-900);
  color: var(--paper);
}
.section-dark a { color: var(--teal-400); }
.section-dark a:hover { color: var(--gold-400); }
.section-dark .section-lead { color: var(--slate-300); }
.section-dark .card {
  background: var(--charcoal-800);
  border-color: rgba(255,255,255,0.08);
  color: var(--paper);
}
.section-dark .card h3 { color: var(--paper); }
.section-dark .muted { color: var(--slate-400); }

.section-inner {
  max-width: var(--max);
  margin: 0 auto;
}

.section-label {
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--teal-500);
  margin: 0 0 0.6rem;
}
.section-dark .section-label { color: var(--teal-400); }

.section h2 {
  font-family: var(--font-display);
  font-size: clamp(1.65rem, 3vw, 2.15rem);
  margin: 0 0 0.75rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  color: var(--charcoal-900);
}
.section-dark h2 { color: var(--paper); }

.section-lead {
  max-width: 42rem;
  color: var(--text-muted);
  margin: 0 0 2rem;
  font-size: 1.02rem;
}

.muted { color: var(--text-muted); font-size: 0.92rem; }
.note {
  font-size: 0.88rem;
  color: var(--text-muted);
  border-left: 3px solid var(--gold-500);
  padding: 0.65rem 0 0.65rem 1rem;
  margin: 1.25rem 0 0;
  background: rgba(201, 162, 39, 0.06);
}
.section-dark .note {
  background: rgba(201, 162, 39, 0.1);
  color: var(--slate-300);
}

/* —— Timeline —— */
.timeline {
  position: relative;
  margin: 0;
  padding: 0 0 0 1.5rem;
  list-style: none;
  border-left: 2px solid rgba(30, 200, 193, 0.35);
}
.timeline li {
  position: relative;
  padding: 0 0 1.6rem 1.25rem;
}
.timeline li:last-child { padding-bottom: 0; }
.timeline li::before {
  content: "";
  position: absolute;
  left: -1.5rem;
  top: 0.45rem;
  width: 0.65rem;
  height: 0.65rem;
  border-radius: 50%;
  background: var(--teal-500);
  box-shadow: 0 0 0 4px var(--teal-glow);
  transform: translateX(-45%);
}
.timeline .year {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--gold-500);
  letter-spacing: 0.04em;
  margin-bottom: 0.25rem;
}
.timeline p { margin: 0; }

/* —— Cards / grids —— */
.grid-2 {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}
.grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1.25rem;
}

.card {
  background: var(--paper);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
  padding: 1.35rem 1.3rem;
  box-shadow: var(--shadow);
}
.card h3 {
  font-family: var(--font-display);
  font-size: 1.15rem;
  margin: 0 0 0.35rem;
  color: var(--charcoal-900);
}
.card .tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--teal-500);
  margin-bottom: 0.5rem;
}
.card p { margin: 0.5rem 0 0; font-size: 0.95rem; }
.card ul {
  margin: 0.65rem 0 0;
  padding-left: 1.1rem;
  font-size: 0.92rem;
}
.card li { margin-bottom: 0.35rem; }
.ticker {
  font-family: ui-monospace, "SF Mono", Menlo, monospace;
  font-size: 0.8rem;
  color: var(--gold-500);
  font-weight: 600;
}

/* —— Portfolio table —— */
.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
  border: 1px solid var(--slate-200);
  background: var(--paper);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.92rem;
}
th, td {
  text-align: left;
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--slate-200);
  vertical-align: top;
}
th {
  background: var(--charcoal-900);
  color: var(--paper);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.04em;
}
tr:last-child td { border-bottom: 0; }
tr:nth-child(even) td { background: rgba(30, 200, 193, 0.03); }
.badge {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.45rem;
  border-radius: 4px;
  background: var(--teal-glow);
  color: #0d6e69;
  margin-right: 0.35rem;
}
.badge-media {
  background: rgba(201, 162, 39, 0.15);
  color: #8a6e12;
}
.badge-db {
  background: rgba(139, 150, 165, 0.2);
  color: #4a5563;
}

/* —— Quotes —— */
.quote-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
}
blockquote.quote {
  margin: 0;
  padding: 1.4rem 1.35rem;
  background: var(--charcoal-900);
  color: var(--paper);
  border-radius: var(--radius);
  border-top: 3px solid var(--teal-500);
  position: relative;
}
blockquote.quote p {
  margin: 0;
  font-family: var(--font-display);
  font-size: 1.05rem;
  line-height: 1.65;
  font-style: normal;
}
blockquote.quote footer {
  margin-top: 1rem;
  font-size: 0.8rem;
  color: var(--slate-400);
  font-family: var(--font);
}

.pillars {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-top: 1.75rem;
}
.pillar {
  padding: 1.2rem;
  border-radius: var(--radius);
  background: var(--paper);
  border: 1px solid var(--slate-200);
}
.pillar strong {
  display: block;
  color: var(--teal-500);
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  margin-bottom: 0.4rem;
}
.pillar p { margin: 0; font-size: 0.92rem; color: var(--text-muted); }

/* —— Outreach (guidance) —— */
.guidance-banner {
  display: flex;
  gap: 1rem;
  align-items: flex-start;
  padding: 1.1rem 1.25rem;
  background: rgba(201, 162, 39, 0.12);
  border: 1px solid rgba(201, 162, 39, 0.35);
  border-radius: var(--radius);
  margin-bottom: 1.75rem;
  font-size: 0.92rem;
}
.guidance-banner .icon {
  flex-shrink: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--gold-500);
  color: var(--charcoal-950);
  display: grid;
  place-items: center;
  font-weight: 800;
  font-size: 0.9rem;
}

.steps {
  counter-reset: step;
  margin: 0;
  padding: 0;
  list-style: none;
}
.steps li {
  counter-increment: step;
  position: relative;
  padding: 1.25rem 1.25rem 1.25rem 4rem;
  margin-bottom: 0.85rem;
  background: var(--paper);
  border: 1px solid var(--slate-200);
  border-radius: var(--radius);
}
.steps li::before {
  content: counter(step, decimal-leading-zero);
  position: absolute;
  left: 1rem;
  top: 1.25rem;
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 1.1rem;
  color: var(--teal-500);
}
.steps h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-family: var(--font-display);
}
.steps p, .steps ul { margin: 0.4rem 0 0; font-size: 0.95rem; }
.steps ul { padding-left: 1.15rem; }

/* Dark section: light cards need dark text (fix white-on-white) */
.section-dark .steps li {
  color: var(--charcoal-900);
}
.section-dark .steps h3 {
  color: var(--charcoal-900);
}
.section-dark .steps p,
.section-dark .steps li ul,
.section-dark .steps li li {
  color: var(--text-muted);
}
.section-dark .steps strong {
  color: var(--charcoal-900);
}
.section-dark .dont-list {
  color: var(--charcoal-900);
}
.section-dark .dont-list ul {
  color: var(--charcoal-800);
}
.section-dark .guidance-banner {
  color: var(--slate-200);
}
.section-dark .guidance-banner strong {
  color: var(--paper);
}


.email-cta {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  margin-top: 0.75rem;
  padding: 0.65rem 1.1rem;
  background: var(--charcoal-900);
  color: var(--teal-300) !important;
  text-decoration: none !important;
  border-radius: 8px;
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid rgba(30, 200, 193, 0.4);
}
.email-cta:hover {
  background: var(--charcoal-800);
  color: var(--gold-400) !important;
}

.dont-list {
  margin-top: 1.5rem;
  padding: 1.25rem 1.35rem;
  background: #f8ecec;
  border: 1px solid #e8c4c4;
  border-radius: var(--radius);
}
.dont-list h3 {
  margin: 0 0 0.6rem;
  font-size: 1rem;
  color: #8b2e2e;
  font-family: var(--font-display);
}
.dont-list ul { margin: 0; padding-left: 1.2rem; font-size: 0.92rem; }

/* —— Media / controversy —— */
.media-item {
  padding: 1.2rem 0;
  border-bottom: 1px solid var(--slate-200);
}
.media-item:last-child { border-bottom: 0; }
.media-item h3 {
  margin: 0 0 0.4rem;
  font-size: 1.05rem;
  font-family: var(--font-display);
}
.media-item p { margin: 0; font-size: 0.95rem; color: var(--text-muted); }

/* —— Links —— */
.link-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 0.75rem 1.5rem;
}
.link-grid a {
  display: block;
  padding: 0.75rem 1rem;
  background: var(--paper);
  border: 1px solid var(--slate-200);
  border-radius: 8px;
  text-decoration: none;
  color: var(--charcoal-900);
  font-size: 0.92rem;
  font-weight: 500;
}
.link-grid a:hover {
  border-color: var(--teal-500);
  color: #0d6e69;
}
.link-grid a span {
  display: block;
  font-size: 0.75rem;
  font-weight: 400;
  color: var(--text-muted);
  margin-top: 0.2rem;
}

/* —— Footer —— */
.site-footer {
  background: var(--charcoal-950);
  color: var(--slate-400);
  padding: 2.5rem 1.25rem 2rem;
  font-size: 0.85rem;
}
.footer-inner {
  max-width: var(--max);
  margin: 0 auto;
}
.site-footer h2 {
  font-family: var(--font-display);
  color: var(--paper);
  font-size: 1.1rem;
  margin: 0 0 1rem;
}
.sources {
  columns: 2;
  column-gap: 2rem;
  margin: 0 0 1.5rem;
  padding-left: 1.1rem;
}
.sources li {
  break-inside: avoid;
  margin-bottom: 0.45rem;
}
.sources a { color: var(--teal-400); word-break: break-all; }
.footer-meta {
  border-top: 1px solid rgba(255,255,255,0.08);
  padding-top: 1.25rem;
  line-height: 1.65;
}

/* —— Utilities —— */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0,0,0,0);
  border: 0;
}

@media (max-width: 900px) {
  .hero-inner { grid-template-columns: 1fr; }
  .grid-2, .grid-3, .quote-grid, .pillars, .link-grid { grid-template-columns: 1fr; }
  .sources { columns: 1; }
  .nav-toggle { display: inline-block; }
  .nav-wrap {
    display: none;
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    flex-direction: column;
    align-items: stretch;
    background: var(--charcoal-950);
    padding: 1rem 1.25rem 1.25rem;
    border-bottom: 1px solid rgba(30, 200, 193, 0.15);
    gap: 1rem;
  }
  .nav-wrap.open { display: flex; }
  .site-nav {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.65rem;
  }
  .site-nav a { font-size: 0.95rem; }
  .header-inner { position: relative; }
  .fact-list li { grid-template-columns: 1fr; gap: 0.15rem; }
}

@media (max-width: 560px) {
  .hero { padding: 3.25rem 1rem 3rem; }
  .section { padding: 2.75rem 1rem; }
  .steps li { padding-left: 3.5rem; }
}
