/* ===========================================================
   IcontainU landing page - styles
   Apple-flavoured: system fonts, soft neutrals, blue accent,
   prefers-color-scheme dark mode.
   =========================================================== */

:root {
  --blue: #0071e3;
  --blue-hover: #0077ed;
  --blue-press: #006edb;

  --bg: #fbfbfd;
  --bg-muted: #f5f5f7;
  --bg-accent: #0a84ff;          /* used on the MCP band */
  --surface: #ffffff;
  --surface-2: #fafafa;

  --text: #1d1d1f;
  --text-soft: #424245;
  --text-mute: #6e6e73;
  --border: #d2d2d7;
  --border-soft: #e5e5ea;

  --radius: 14px;
  --radius-lg: 20px;
  --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.04), 0 2px 6px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.06), 0 12px 32px rgba(0, 0, 0, 0.08);
  --shadow-shot: 0 20px 60px rgba(0, 0, 0, 0.16), 0 4px 12px rgba(0, 0, 0, 0.08);

  --container: 1080px;
  --font: -apple-system, BlinkMacSystemFont, "SF Pro Text", "SF Pro Display",
    "Helvetica Neue", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei",
    system-ui, sans-serif;
  --mono: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #000000;
    --bg-muted: #0a0a0c;
    --surface: #1c1c1e;
    --surface-2: #242426;
    --text: #f5f5f7;
    --text-soft: #d6d6db;
    --text-mute: #8e8e93;
    --border: #38383c;
    --border-soft: #2c2c2e;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.4);
    --shadow-md: 0 8px 24px rgba(0, 0, 0, 0.5);
    --shadow-shot: 0 24px 70px rgba(0, 0, 0, 0.6), 0 4px 12px rgba(0, 0, 0, 0.4);
  }
}

/* ---------- reset ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 17px;
  line-height: 1.6;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
code, pre { font-family: var(--mono); }
code {
  font-size: 0.9em;
  background: var(--bg-muted);
  border: 1px solid var(--border-soft);
  padding: 0.1em 0.4em;
  border-radius: 6px;
  word-break: break-word;
}

h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0; font-weight: 600; }
h2 { font-size: clamp(1.7rem, 3vw, 2.4rem); }
h3 { font-size: 1.2rem; }
p { margin: 0; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 24px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5em;
  font: inherit;
  font-weight: 500;
  line-height: 1;
  padding: 0.7em 1.2em;
  border-radius: 980px;
  border: 1px solid transparent;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s, transform 0.05s;
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--blue); color: #fff; }
.btn-primary:hover { background: var(--blue-hover); }
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn-ghost:hover { background: var(--bg-muted); }
.btn-lg { padding: 0.95em 1.6em; font-size: 1.05rem; }
.btn-meta {
  font-size: 0.78rem;
  opacity: 0.85;
  font-weight: 400;
  margin-left: 0.2em;
}
.btn-meta::before { content: "·"; margin: 0 0.4em; }

/* ---------- nav ---------- */
.nav {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(251, 251, 253, 0.72);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s, background 0.2s;
}
@media (prefers-color-scheme: dark) {
  .nav { background: rgba(0, 0, 0, 0.6); }
}
.nav.scrolled { border-bottom-color: var(--border-soft); }
.nav-inner {
  display: flex;
  align-items: center;
  gap: 1.2rem;
  height: 56px;
}
.brand { display: inline-flex; align-items: center; gap: 0.55rem; font-weight: 600; font-size: 1.05rem; }
.brand-icon { width: 28px; height: 28px; border-radius: 7px; }
.nav-links { display: flex; gap: 1.3rem; margin-left: 0.5rem; }
.nav-links a {
  font-size: 0.95rem;
  color: var(--text-soft);
  transition: color 0.15s;
}
.nav-links a:hover { color: var(--text); }
.nav-actions { margin-left: auto; display: flex; align-items: center; gap: 0.6rem; }

.lang-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.25em;
  font: inherit;
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-mute);
  background: transparent;
  border: 1px solid var(--border-soft);
  border-radius: 980px;
  padding: 0.35em 0.7em;
  cursor: pointer;
}
.lang-toggle .lang-opt { transition: color 0.15s; }
.lang-toggle .lang-opt.active { color: var(--blue); }
.lang-sep { opacity: 0.5; }

/* ---------- section scaffolding ---------- */
.section { padding: 96px 0; }
section[id], main#top { scroll-margin-top: 72px; }
.section-muted { background: var(--bg-muted); }
.section-head { max-width: 720px; margin: 0 auto 56px; text-align: center; }
.section-head h2 { margin-bottom: 0.5rem; }
.section-head p { color: var(--text-mute); font-size: 1.08rem; }

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--blue);
  margin: 0 0 0.6rem;
}

/* ---------- hero ---------- */
.hero {
  padding: 88px 0 64px;
  text-align: center;
  background:
    radial-gradient(1200px 500px at 50% -10%, rgba(10, 132, 255, 0.12), transparent 70%);
}
.hero-inner { max-width: 880px; }
.hero .eyebrow { color: var(--text-mute); }
.hero-title {
  font-size: clamp(2.3rem, 5.5vw, 3.6rem);
  font-weight: 700;
  margin: 0.6rem 0 1.1rem;
}
.hero-title code, .hero-sub code, h3 code, .feature code { background: none; border: none; padding: 0; font-size: inherit; }
.hero-sub {
  font-size: 1.18rem;
  color: var(--text-soft);
  max-width: 680px;
  margin: 0 auto 2rem;
}
.hero-cta { display: flex; gap: 0.8rem; justify-content: center; flex-wrap: wrap; }
.hero-note { margin-top: 1.1rem; color: var(--text-mute); font-size: 0.9rem; }

.hero-shot {
  margin: 3.5rem auto 0;
  max-width: 940px;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-shot);
  border: 1px solid var(--border-soft);
  background: var(--surface);
}
.hero-shot img { width: 100%; }

/* ---------- highlights ---------- */
.highlights { display: grid; grid-template-columns: 1fr 1fr; gap: 28px; }
.highlight-card {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}
.highlight-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); }
.highlight-media { background: var(--bg-muted); border-bottom: 1px solid var(--border-soft); }
.highlight-media img { width: 100%; }
.highlight-body { padding: 28px 28px 32px; }
.highlight-tag { font-weight: 600; font-size: 0.95rem; }
.highlight-body h3 { margin: 0.5rem 0 0.6rem; font-size: 1.3rem; }
.highlight-body p { color: var(--text-soft); }

/* ---------- feature grid ---------- */
.feature-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; }
.feature {
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  padding: 26px 24px;
  box-shadow: var(--shadow-sm);
}
.feature-icon { font-size: 1.8rem; line-height: 1; margin-bottom: 0.6rem; }
.feature-icon.lg { font-size: 2.4rem; }
.feature h3 { margin-bottom: 0.4rem; }
.feature p { color: var(--text-soft); font-size: 0.97rem; }

/* ---------- split (compose) ---------- */
.split { display: grid; grid-template-columns: 1.1fr 0.9fr; gap: 56px; align-items: center; }
.split-text .eyebrow { display: inline-block; }
.split-text h2 { margin: 0.4rem 0 1rem; }
.split-text > p { color: var(--text-soft); margin-bottom: 1.2rem; }
.check-list { list-style: none; padding: 0; margin: 0 0 1.4rem; display: grid; gap: 0.6rem; }
.check-list li {
  position: relative;
  padding-left: 1.7em;
  color: var(--text-soft);
}
.check-list li::before {
  content: "✓";
  position: absolute;
  left: 0;
  top: 0;
  color: var(--blue);
  font-weight: 700;
}
.split-note { color: var(--text-mute); font-size: 0.95rem; margin-bottom: 1.2rem; }
.split-media {
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-soft);
  background: var(--surface);
}
.split-media img { width: 100%; }

/* ---------- MCP callout ---------- */
.section-accent { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-muted) 100%); }
.mcp-card {
  background: linear-gradient(135deg, #0a84ff 0%, #0064d6 100%);
  color: #fff;
  border-radius: var(--radius-lg);
  padding: 48px;
  box-shadow: var(--shadow-md);
}
.mcp-head { display: flex; gap: 1rem; align-items: center; margin-bottom: 1.2rem; }
.mcp-head .feature-icon { background: rgba(255, 255, 255, 0.15); border-radius: var(--radius); padding: 0.5rem; margin: 0; }
.mcp-head .eyebrow { color: rgba(255, 255, 255, 0.85); margin: 0; }
.mcp-head h2 { color: #fff; }
.mcp-lead { font-size: 1.12rem; max-width: 760px; color: rgba(255, 255, 255, 0.92); }
.mcp-lead em { font-style: normal; font-weight: 600; color: #fff; }
.mcp-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
  margin: 28px 0;
}
.mcp-group {
  background: rgba(255, 255, 255, 0.12);
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: var(--radius);
  padding: 16px 18px;
}
.mcp-group-name { display: block; font-weight: 600; margin-bottom: 0.3rem; }
.mcp-tools { font-family: var(--mono); font-size: 0.85rem; color: rgba(255, 255, 255, 0.88); word-break: break-word; }
.mcp-foot { display: flex; gap: 24px; align-items: center; flex-wrap: wrap; }
.mcp-foot .btn-ghost { background: rgba(255, 255, 255, 0.14); color: #fff; border-color: rgba(255, 255, 255, 0.3); }
.mcp-foot .btn-ghost:hover { background: rgba(255, 255, 255, 0.22); }
.mcp-foot img {
  max-height: 220px;
  border-radius: var(--radius);
  box-shadow: var(--shadow-md);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

/* ---------- why ---------- */
.why-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 28px; }
.why h3 { margin-bottom: 0.5rem; }
.why p { color: var(--text-soft); }

/* ---------- screenshots ---------- */
.shot-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 22px; }
.shot {
  margin: 0;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  transition: transform 0.2s, box-shadow 0.2s;
}
.shot:hover { transform: translateY(-3px); box-shadow: var(--shadow-md); }
.shot img { width: 100%; }
.shot figcaption { padding: 12px 16px; font-size: 0.9rem; color: var(--text-mute); border-top: 1px solid var(--border-soft); }

/* ---------- install ---------- */
.install-inner { max-width: 760px; }
.steps { list-style: none; padding: 0; margin: 0; display: grid; gap: 28px; }
.steps li { display: grid; grid-template-columns: 44px 1fr; gap: 18px; align-items: start; }
.step-num {
  width: 36px; height: 36px;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--blue); color: #fff;
  border-radius: 50%;
  font-weight: 600;
}
.step-body h3 { margin-bottom: 0.4rem; }
.step-body p { color: var(--text-soft); margin-bottom: 0.8rem; }
.step-body .btn { margin-top: 0.2rem; }
pre {
  background: var(--surface-2);
  border: 1px solid var(--border-soft);
  border-radius: 10px;
  padding: 14px 16px;
  overflow-x: auto;
  margin: 0.4rem 0 0.6rem;
}
pre code { background: none; border: none; padding: 0; font-size: 0.88rem; color: var(--text-soft); }

/* ---------- footer ---------- */
.footer { border-top: 1px solid var(--border-soft); background: var(--bg-muted); padding: 56px 0 40px; }
.footer-inner { display: grid; gap: 28px; }
.footer-brand { display: flex; gap: 14px; align-items: center; }
.footer-brand p { color: var(--text-mute); font-size: 0.95rem; margin-top: 2px; }
.footer-links { display: flex; gap: 1.4rem; flex-wrap: wrap; }
.footer-links a { color: var(--text-soft); font-size: 0.95rem; }
.footer-links a:hover { color: var(--blue); }
.footer-meta { color: var(--text-mute); font-size: 0.88rem; line-height: 1.7; }

/* ---------- responsive ---------- */
@media (max-width: 880px) {
  .nav-links { display: none; }
  .section { padding: 72px 0; }
  .highlights { grid-template-columns: 1fr; }
  .feature-grid { grid-template-columns: 1fr 1fr; }
  .split { grid-template-columns: 1fr; gap: 32px; }
  .mcp-grid { grid-template-columns: 1fr 1fr; }
  .why-grid { grid-template-columns: 1fr; }
  .shot-grid { grid-template-columns: 1fr 1fr; }
  .mcp-card { padding: 32px 24px; }
}
@media (max-width: 560px) {
  .container { padding: 0 18px; }
  .feature-grid { grid-template-columns: 1fr; }
  .shot-grid { grid-template-columns: 1fr; }
  .mcp-grid { grid-template-columns: 1fr; }
  .hero { padding: 56px 0 40px; }
  .btn-ghost.hide-sm, .nav-actions .btn-ghost { display: none; }
  .steps li { grid-template-columns: 32px 1fr; gap: 12px; }
}

/* respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; }
}
