/* Callan official site. Colors follow the desktop app theme. */
:root {
  --bg: #F5F7FA;
  --bg-hero: #EEF3FF;
  --text: #1B2330;
  --sub: #5F6B7A;
  --muted: #8A95A3;
  --brand: #2F6BFF;
  --brand-hover: #1F56E0;
  --brand-soft: #E8EFFF;
  --line: #E4E8EE;
  --card: #ffffff;
  --danger-soft: #FFF7E6;
  --danger-line: #F59E0B;
  --shadow: 0 1px 2px rgba(16, 24, 40, 0.04), 0 16px 40px rgba(16, 24, 40, 0.07);
  --radius: 16px;
  --max: 1120px;
  --header-h: 64px;
  --font: "Segoe UI", "PingFang SC", "Hiragino Sans GB", "Microsoft YaHei", system-ui, -apple-system, sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
}

body {
  margin: 0;
  font: 16px/1.65 var(--font);
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: var(--brand); text-decoration-thickness: 1px; text-underline-offset: 2px; }
a:hover { color: var(--brand-hover); }

.skip {
  position: absolute;
  left: -999px;
  top: 8px;
  background: var(--brand);
  color: #fff;
  padding: 8px 14px;
  border-radius: 8px;
  z-index: 100;
}
.skip:focus { left: 8px; }

.wrap {
  width: min(var(--max), calc(100% - 40px));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(245, 247, 250, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner {
  min-height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
  padding: 10px 0;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 18px;
  letter-spacing: -0.02em;
}
.brand:hover { color: var(--text); }
.brand img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
}
.nav {
  display: flex;
  align-items: center;
  gap: 6px 18px;
  flex-wrap: wrap;
}
.nav a {
  color: var(--sub);
  text-decoration: none;
  font-size: 15px;
}
.nav a:hover { color: var(--text); }
.nav a[aria-current="page"] { color: var(--text); font-weight: 600; }

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 44px;
  padding: 10px 18px;
  border-radius: 12px;
  border: 1px solid transparent;
  font: 600 15px/1 var(--font);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease, border-color 0.15s ease;
}
.btn-primary {
  background: var(--brand);
  color: #fff;
}
.btn-primary:hover { background: var(--brand-hover); color: #fff; }
.btn-ghost {
  background: #fff;
  color: var(--text);
  border-color: var(--line);
}
.btn-ghost:hover { background: var(--brand-soft); color: var(--text); }
.btn[aria-disabled="true"],
.btn:disabled {
  background: #D7DDE6;
  color: #6B7584;
  border-color: transparent;
  cursor: not-allowed;
  pointer-events: none;
}
.btn-row { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }

/* Hero */
.hero {
  background:
    radial-gradient(1200px 480px at 80% 0%, #dfe8ff 0%, transparent 70%),
    linear-gradient(180deg, var(--bg-hero) 0%, var(--bg) 100%);
  padding: 36px 0 20px;
  overflow: hidden;
}
.hero-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 24px;
  align-items: center;
}
.eyebrow {
  color: var(--brand);
  font-weight: 650;
  font-size: 13px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin: 0 0 10px;
}
.hero h1 {
  margin: 0 0 10px;
  font-size: clamp(36px, 8vw, 64px);
  line-height: 1.1;
  letter-spacing: -0.03em;
}
.hero .tagline {
  margin: 0 0 18px;
  font-size: clamp(20px, 3vw, 26px);
  color: var(--sub);
  font-weight: 500;
}
.hero .lead {
  margin: 0 0 24px;
  font-size: 17px;
  color: var(--sub);
  max-width: 38em;
}
.hero-art {
  display: flex;
  justify-content: center;
  pointer-events: none;
}
.hero-art img {
  width: min(420px, 80vw);
  filter: drop-shadow(0 24px 40px rgba(47, 107, 255, 0.12));
}

/* Sections */
.section { padding: 64px 0; }
.section h2 {
  margin: 0 0 10px;
  font-size: clamp(24px, 4vw, 32px);
  letter-spacing: -0.02em;
}
.section .intro {
  margin: 0 0 32px;
  color: var(--sub);
  max-width: 40em;
}
.features {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}
.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 22px 22px 20px;
  box-shadow: 0 1px 2px rgba(16, 24, 40, 0.03);
}
.card h3 {
  margin: 0 0 8px;
  font-size: 18px;
}
.card p { margin: 0; color: var(--sub); }

.product {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: center;
}
.shot {
  background: #E4E8F0;
  border-radius: 20px;
  padding: 18px;
  box-shadow: var(--shadow);
}
.shot img, .shot picture { border-radius: 12px; overflow: hidden; width: 100%; }
.shot img { width: 100%; }
.caption { margin: 10px 0 0; color: var(--muted); font-size: 13px; text-align: center; }

.download-panel {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 20px;
  padding: 28px 24px;
  box-shadow: var(--shadow);
  max-width: 640px;
}
.download-panel p { color: var(--sub); }
.note {
  margin: 14px 0 0;
  padding: 12px 14px;
  background: var(--brand-soft);
  border-radius: 12px;
  color: var(--text);
  font-size: 14px;
}

/* Legal / help article */
.article {
  max-width: 760px;
  margin: 0 auto;
  padding: 40px 0 72px;
}
.article h1 { font-size: clamp(26px, 4vw, 34px); letter-spacing: -0.02em; margin: 0 0 8px; }
.article h2 { font-size: 19px; margin: 28px 0 8px; }
.article h3 { font-size: 16px; margin: 22px 0 8px; }
.article p, .article li { color: var(--text); }
.article ul, .article ol { padding-left: 1.3em; }
.article hr { border: 0; border-top: 1px solid var(--line); margin: 36px 0; }
.crumb {
  font-size: 13px;
  color: var(--muted);
  margin: 0 0 18px;
}
.crumb a { color: var(--sub); text-decoration: none; }
.crumb a:hover { color: var(--brand); }
.draft-banner {
  margin: 0 0 24px;
  padding: 12px 14px;
  background: var(--danger-soft);
  border-left: 4px solid var(--danger-line);
  border-radius: 0 12px 12px 0;
  color: #7A4F01;
}
.updated { color: var(--muted); font-size: 14px; margin: 0 0 20px; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--line);
  background: #fff;
  padding: 28px 0 36px;
  color: var(--sub);
  font-size: 14px;
}
.footer-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  justify-content: space-between;
  align-items: flex-start;
}
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 16px; }
.footer-links a { color: var(--sub); text-decoration: none; }
.footer-links a:hover { color: var(--text); }

/* 404 */
.not-found { text-align: center; padding: 64px 0 80px; }
.not-found img { width: 200px; margin: 0 auto 20px; }

@media (min-width: 720px) {
  .features { grid-template-columns: 1fr 1fr; }
  .features .card:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .hero { padding: 56px 0 28px; }
}

@media (min-width: 960px) {
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; gap: 40px; }
  .hero-art { justify-content: flex-end; }
  .hero-art img { width: min(520px, 42vw); }
  .features { grid-template-columns: repeat(3, 1fr); }
  .features .card:last-child:nth-child(odd) { grid-column: auto; }
  .product { grid-template-columns: 1.15fr 0.85fr; }
  .product.flip { grid-template-columns: 0.85fr 1.15fr; }
  .product.flip .shot { order: 0; }
  .product.flip .product-copy { order: 1; }
}

/* Footer logo (small product mark) */
.footer-brand { display: flex; align-items: center; gap: 8px; }
.footer-brand img { width: 20px; height: 20px; border-radius: 50%; }

/* ---- Homepage v2 (preview) ---- */
.hero-v2 { padding: 28px 0 36px; }
.hero-v2-grid {
  display: grid;
  grid-template-columns: 1fr;
  grid-template-areas: "copy" "demo" "cta";
  gap: 20px;
  align-items: center;
}
.hero-v2-copy { grid-area: copy; }
.hero-v2-cta { grid-area: cta; }
.hero-v2 h1 { font-size: clamp(34px, 9vw, 60px); margin: 0 0 14px; }
.hero-v2 .lead { margin: 0; }
.hero-note { margin: 14px 0 0; color: var(--muted); font-size: 14px; max-width: 36em; }
.br-mobile { display: none; }
.demo { grid-area: demo; margin: 0; justify-self: center; width: min(100%, 440px); }
.demo-window {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 18px;
  overflow: hidden;
  box-shadow: 0 2px 4px rgba(16,24,40,.04), 0 24px 60px rgba(31,64,160,.16);
}
.demo-bar {
  display: flex; align-items: center; gap: 6px;
  height: 34px; padding: 0 12px;
  background: #F2F4F8; border-bottom: 1px solid var(--line);
}
.demo-bar span { width: 10px; height: 10px; border-radius: 50%; background: #D5DAE3; }
.demo-bar b { margin-left: 8px; font-size: 12px; font-weight: 600; color: var(--sub); }
.demo-video { display: block; width: 100%; height: auto; aspect-ratio: 3 / 4; background: #F5F7FA; }
.demo figcaption { margin: 10px 4px 0; color: var(--muted); font-size: 12.5px; text-align: center; line-height: 1.5; }
.section-tight { padding-top: 8px; }
.modes { display: grid; grid-template-columns: 1fr; gap: 16px; }
.mode-card { position: relative; }
.mode-tag {
  display: inline-block; margin-bottom: 10px; padding: 2px 10px;
  border-radius: 999px; font-size: 13px; font-weight: 600;
  background: var(--brand-soft); color: var(--brand);
}
.mode-tag-task { background: #EEF0F4; color: var(--sub); }
@media (max-width: 480px) {
  .br-mobile { display: inline; }
  .hero-v2 { padding-top: 20px; }
}
@media (min-width: 720px) {
  .modes { grid-template-columns: 1fr 1fr; }
}
@media (min-width: 960px) {
  .hero-v2 { padding: 48px 0 56px; }
  .hero-v2-grid {
    grid-template-columns: 1.1fr 0.9fr;
    grid-template-areas: "copy demo" "cta demo";
    grid-template-rows: auto 1fr;
    column-gap: 56px; row-gap: 26px;
  }
  .hero-v2-copy { align-self: end; }
  .hero-v2-cta { align-self: start; }
  .demo { justify-self: end; width: min(420px, 100%); }
  .demo-video { max-height: calc(100vh - 200px); object-fit: contain; }
}
