/* === Design System === */
:root {
  --bg: #faf8f5;
  --bg-warm: #f3efe9;
  --bg-terminal: #1e1e22;
  --border: #e4dfd7;
  --text: #2c2a28;
  --text-muted: #807a72;
  --accent: #c2603a;
  --accent-hover: #a8502f;
  --success: #458b5b;
  --font-heading: "Instrument Serif", Georgia, serif;
  --font-body: "Satoshi", -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: "IBM Plex Mono", "Fira Code", monospace;
  --shadow: 0 4px 24px rgba(0,0,0,0.06);
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--bg-warm);
  padding: 0.12em 0.4em;
  border-radius: 4px;
  color: var(--accent);
}

.container { max-width: 1100px; margin: 0 auto; padding: 0 1.5rem; }
.narrow { max-width: 620px; margin: 0 auto; }

/* Animations */
.fade-in {
  opacity: 0;
  transform: translateY(12px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.fade-in.visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  .fade-in { opacity: 1; transform: none; transition: none; }
  .cursor { animation: none !important; }
}

/* === Hero === */
.hero {
  padding: 4.5rem 0 3rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 3rem;
  align-items: start;
}

.hero h1 {
  font-family: var(--font-heading);
  font-size: clamp(2.2rem, 4vw, 3rem);
  font-weight: 400;
  line-height: 1.15;
  margin-bottom: 0.5rem;
}

.hero em { font-style: italic; color: var(--accent); }

.subtitle {
  color: var(--text-muted);
  font-size: 1.05rem;
  line-height: 1.55;
  max-width: 520px;
  margin-bottom: 1.75rem;
}

.hero-demo {
  display: flex;
  flex-direction: column;
  align-items: stretch;
  padding-top: 0.25rem;
}

/* Video thumbnail */
.video-thumb {
  position: relative;
  display: block;
  width: 100%;
  border: none;
  padding: 0;
  cursor: pointer;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: none;
}

.video-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
}

.play-btn {
  position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%);
  transition: transform 0.2s;
}

.video-thumb:hover .play-btn { transform: translate(-50%, -50%) scale(1.1); }

/* Video modal */
.video-modal {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.video-modal.active { display: flex; }

.video-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.75);
}

.video-modal-content {
  position: relative;
  width: 90%;
  max-width: 900px;
}

.video-modal-close {
  position: absolute;
  top: -2.5rem; right: 0;
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
}

.video-wrap {
  position: relative;
  width: 100%;
  padding-bottom: 56.25%;
  border-radius: 10px;
  overflow: hidden;
}

.video-wrap iframe {
  position: absolute;
  top: 0; left: 0;
  width: 100%; height: 100%;
}

.btn-github {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.65rem 1.25rem;
  background: var(--text);
  color: #fff;
  border-radius: 8px;
  font-size: 0.95rem;
  font-weight: 600;
  transition: background 0.2s;
}
.btn-github:hover { background: #1a1917; text-decoration: none; }
.btn-github--full {
  display: flex;
  justify-content: center;
  width: 100%;
  margin-top: 0.75rem;
}
.btn-github .stars-count:not(:empty)::before { content: " · "; }
.btn-github .stars-count { color: rgba(255,255,255,0.7); }

.install-cmd {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--bg-terminal);
  border: 2px solid var(--accent);
  border-radius: 8px;
  padding: 0.7rem 0.85rem 0.7rem 1rem;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: #d4cfc7;
  margin-bottom: 0.75rem;
  cursor: pointer;
  transition: border-color 0.2s;
}
.install-cmd {
  position: relative;
}
.install-cmd:hover {
  border-color: var(--accent-hover);
}
.install-copied {
  position: absolute;
  right: 0;
  left: 0;
  top: 0;
  bottom: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-terminal);
  border-radius: 6px;
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}
.install-cmd.show-copied .install-copied {
  opacity: 1;
}

.install-flag {
  position: absolute;
  top: -1.1rem;
  left: -2px;
  background: var(--accent);
  color: #fff;
  font-family: var(--font-body);
  font-size: 0.65rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  padding: 0.2rem 0.75rem;
  border-radius: 4px 4px 0 0;
  line-height: 1.3;
  z-index: 0;
}
.install-note {
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.35rem;
  text-align: center;
  font-weight: 500;
  font-style: italic;
}
.install-prompt { color: var(--accent); user-select: none; margin-right: 0.25rem; }
.install-cmd code { background: none; padding: 0; color: inherit; font-size: inherit; }


.btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.75rem 1.5rem;
  background: var(--accent);
  color: #fff;
  border-radius: 8px;
  font-size: 1rem;
  font-weight: 700;
  transition: background 0.2s;
}
.btn-primary:hover { background: var(--accent-hover); text-decoration: none; }

.copy-btn {
  display: inline-flex;
  align-items: center;
  background: none;
  border: none;
  color: #666;
  cursor: pointer;
  padding: 0.15rem;
  border-radius: 3px;
  transition: color 0.2s;
  flex-shrink: 0;
}
.copy-btn:hover { color: #bbb; }
.copy-btn.copied { color: var(--success); }



blockquote {
  border-left: 2px solid var(--accent);
  padding-left: 1rem;
}

blockquote p {
  font-family: var(--font-heading);
  font-size: 1rem;
  font-style: italic;
  margin-bottom: 0.25rem;
  line-height: 1.45;
}

blockquote cite {
  font-family: var(--font-body);
  font-style: normal;
  font-size: 0.8rem;
  color: var(--text-muted);
}

.examples {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
}

.example-tag {
  padding: 0.3rem 0.7rem;
  background: var(--bg-warm);
  border: 1px solid var(--border);
  border-radius: 20px;
  font-size: 0.78rem;
  color: var(--text-muted);
}

/* === Quotes Section === */
.quotes-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem;
}

/* === Demo === */
.demo-placeholder {
  aspect-ratio: 16 / 9;
  background: var(--bg-warm);
  border: 2px dashed var(--border);
  border-radius: 12px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  color: var(--text-muted);
}

.demo-placeholder p {
  font-size: 0.9rem;
}

/* === Video Comparison === */
.section-heading {
  font-family: var(--font-heading);
  font-size: 2rem;
  margin-bottom: 1.5rem;
}
.section-sub {
  color: var(--text-muted);
  margin-bottom: 2rem;
}
.video-comparison {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.5rem;
}
@media (max-width: 768px) {
  .video-comparison { grid-template-columns: 1fr; }
}
.video-comparison-card {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  justify-content: center;
}
.video-comparison-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--text-muted);
}
.video-comparison-label--after {
  color: var(--accent);
}
.video-comparison-desc {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 0.5rem;
}
.video-comparison-embed {
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  overflow: hidden;
}
.video-comparison-embed .demo-placeholder {
  height: 100%;
  aspect-ratio: auto;
  border-radius: 0;
}
.video-comparison-embed iframe {
  width: 100%;
  height: 100%;
  border: 0;
}
.video-comparison-explainer {
  margin-top: 0;
  padding: 0.75rem 1rem;
  background: var(--bg-warm);
  border-radius: 8px;
  border-left: 3px solid var(--border);
  font-size: 0.85rem;
  line-height: 1.5;
  color: var(--text-muted);
}
.video-comparison-explainer--after {
  border-left-color: var(--accent);
}
.video-comparison-stats {
  display: flex;
  gap: 1.5rem;
  margin-top: 1rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border);
  font-size: 0.85rem;
  color: var(--muted);
}
.video-comparison-stats .stat strong {
  color: var(--text);
}
.video-comparison-stats .stat-value {
  color: var(--accent);
  font-weight: 600;
}
.video-comparison-footer {
  margin-top: 2rem;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 2rem;
}
.video-comparison-footer-text {
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--text-muted);
}
.video-comparison-footer-text p + p {
  margin-top: 0.5rem;
}
.video-comparison-footer a {
  color: var(--accent);
  text-decoration: underline;
  text-underline-offset: 2px;
}
.video-comparison-cta {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.4rem;
  flex-shrink: 0;
}
.btn-download-job {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  background: var(--accent);
  color: #fff !important;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none !important;
  white-space: nowrap;
}
.btn-download-note {
  font-size: 0.75rem;
  color: var(--text-muted);
  opacity: 0.7;
}

/* Comparison report */
.comparison-report-heading {
  font-family: var(--font-heading);
  font-size: 1.5rem;
  font-weight: 400;
  margin-top: 2.5rem;
  margin-bottom: 0.5rem;
  color: var(--text);
}
.comparison-report-subheading {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.5;
  color: var(--text);
  margin-top: 2.5rem;
  margin-bottom: 0.5rem;
}
.comparison-report-intro {
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 1.25rem;
  color: var(--text-muted);
}
.comparison-report {
  background: var(--bg-terminal);
  border-radius: 12px;
  padding: 1.5rem 1.75rem;
  color: #d4d0c8;
}
.comparison-report-takeaway {
  font-family: var(--font-heading);
  font-size: 1.15rem;
  font-weight: 400;
  font-style: italic;
  color: #e8e4de;
  margin-bottom: 1rem;
}
.comparison-report-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: #8a8580;
  margin-bottom: 1rem;
}
.comparison-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.8rem;
  font-family: var(--font-mono);
}
.comparison-table th,
.comparison-table td {
  padding: 0.45rem 0.6rem;
  text-align: center;
  border-bottom: 1px solid rgba(255,255,255,0.07);
}
.comparison-table th:first-child,
.comparison-table td:first-child {
  text-align: left;
}
.comparison-table thead th {
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #8a8580;
  font-weight: 500;
  padding-bottom: 0.6rem;
  border-bottom: 1px solid rgba(255,255,255,0.12);
}
.comparison-table td.check {
  color: #6ecf8a;
}
.comparison-table td.miss {
  color: #e05a47;
}
.comparison-table td:not(:first-child) {
  font-size: 1rem;
}
.comparison-table .table-note {
  font-size: 0.65rem;
  opacity: 0.6;
}
.comparison-report-attribution {
  margin-top: 1.25rem;
  text-align: right;
  font-size: 0.7rem;
  color: #a8a29e;
  opacity: 0.7;
}
.comparison-report-attribution a {
  color: #a8a29e;
  text-decoration: none;
}
.comparison-report-attribution a:hover {
  color: var(--accent);
}
.expandable-table [data-detail] {
  display: none;
}
.expandable-table.expanded [data-summary] {
  display: none;
}
.expandable-table.expanded [data-detail] {
  display: table;
}
.expandable-table-toggle {
  display: block;
  width: 100%;
  margin-top: 0.75rem;
  padding: 0.5rem;
  background: transparent;
  border: 1px dashed var(--border);
  border-radius: 6px;
  color: var(--text-muted);
  font-family: var(--font-mono);
  font-size: 0.75rem;
  cursor: pointer;
  transition: color 0.2s, border-color 0.2s;
}
.expandable-table-toggle:hover {
  color: var(--accent);
  border-color: var(--accent);
}
.expandable-table-toggle-hide {
  display: none;
}
.expandable-table.expanded .expandable-table-toggle-show {
  display: none;
}
.expandable-table.expanded .expandable-table-toggle-hide {
  display: inline;
}
.table-category-row td {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--text-muted);
  padding-top: 0.75rem !important;
  border-bottom: 1px solid var(--border);
}
.comparison-report-bottom {
  margin-top: 1.25rem;
  font-size: 0.85rem;
  line-height: 1.6;
  color: #a8a29e;
}
.comparison-report-bottom strong {
  color: #e8e4de;
}
@media (max-width: 768px) {
  .comparison-table { font-size: 0.7rem; }
  .comparison-table th,
  .comparison-table td { padding: 0.35rem 0.3rem; }
  .comparison-report { padding: 1rem; }
}
.btn-download-job {
  display: inline-block;
  padding: 0.5rem 1.25rem;
  background: var(--accent);
  color: #fff !important;
  border-radius: 6px;
  font-weight: 600;
  font-size: 0.85rem;
  text-decoration: none !important;
  white-space: nowrap;
  flex-shrink: 0;
}

/* === PDF Thumbnails === */
.pdf-thumb {
  position: relative;
  display: block;
  width: 100%;
  border: none;
  padding: 0;
  cursor: pointer;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
  background: #fff;
}
.pdf-thumb img {
  display: block;
  width: 100%;
  aspect-ratio: 8.5 / 11;
  object-fit: cover;
  object-position: top;
}
.pdf-thumb--center {
  display: flex;
  align-items: center;
  justify-content: center;
}
.pdf-thumb--grid {
  background: var(--bg-warm);
}
.pdf-thumb--grid img {
  aspect-ratio: auto;
  width: 100%;
  height: auto;
}
.pdf-thumb-pages {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  padding: 6px;
}
.pdf-thumb-pages img {
  border-radius: 4px;
  box-shadow: 0 1px 4px rgba(0,0,0,0.1);
}
.pdf-thumb-overlay {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  background: rgba(0,0,0,0);
  color: #fff;
  font-size: 0.85rem;
  font-weight: 600;
  opacity: 0;
  transition: opacity 0.2s, background 0.2s;
}
.pdf-thumb:hover .pdf-thumb-overlay {
  opacity: 1;
  background: rgba(0,0,0,0.45);
}

/* === PDF Overlay Viewer === */
.pdf-overlay {
  display: none;
  position: fixed;
  inset: 0;
  z-index: 1000;
}
.pdf-overlay.active {
  display: flex;
  flex-direction: column;
}
.pdf-overlay-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.85);
}
.pdf-overlay-content {
  position: relative;
  display: flex;
  flex-direction: column;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.pdf-overlay-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.5rem;
  color: #fff;
  flex-shrink: 0;
  position: relative;
  z-index: 1;
}
.pdf-overlay-title {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  opacity: 0.7;
}
.pdf-overlay-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
  line-height: 1;
  padding: 0 0.5rem;
}
.pdf-overlay-pages {
  flex: 1;
  overflow-y: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 0 1.5rem 2rem;
  -webkit-overflow-scrolling: touch;
}
.pdf-overlay-pages img {
  display: block;
  max-width: 720px;
  width: 100%;
  border-radius: 4px;
  box-shadow: 0 2px 20px rgba(0,0,0,0.4);
}

/* === Tips === */
.tips-list {
  display: flex;
  flex-direction: column;
  gap: 2.5rem;
}
.tip-item {
  padding-left: 2.5rem;
  position: relative;
}
.tip-title {
  font-family: var(--font-body);
  font-size: 1.1rem;
  font-weight: 600;
  line-height: 1.5;
  color: var(--text);
  margin: 0 0 0.4rem;
}
.tip-highlight {
  color: var(--accent);
  font-weight: 600;
}
.tip-desc {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--text-muted);
  margin: 0.3rem 0 0;
  max-width: 38rem;
}
.tip-title code,
.tip-desc code {
  font-family: var(--font-mono);
  font-size: 0.8em;
  background: rgba(255,255,255,0.08);
  padding: 0.15em 0.4em;
  border-radius: 3px;
  color: var(--text);
}
.tip-desc em {
  font-style: italic;
  color: var(--text);
}
.tip-number {
  position: absolute;
  left: 0;
  font-family: var(--font-mono);
  font-style: normal;
  font-size: 0.8rem;
  color: var(--text-muted);
  top: 0.45em;
}

/* === Skills Grid === */
.skills-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem 3rem;
}
@media (max-width: 768px) {
  .skills-grid { grid-template-columns: 1fr; }
}
.skill-card {
  padding: 0;
}
.skill-tag {
  display: none;
}
.skill-name {
  font-size: 1.1rem;
  font-weight: 700;
  margin: 0 0 0.25rem;
}
.skill-desc {
  font-size: 0.95rem;
  line-height: 1.5;
  color: var(--text-muted);
}
/* === Skills Compose === */
.skills-compose-note {
  margin-top: 2rem;
  font-size: 0.95rem;
  color: var(--text-muted);
}

.skill-meta {
  margin-top: 0.35rem;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--accent);
  opacity: 0.8;
}

/* === How It Works === */
.how-section {
  padding: 2rem 0 3rem;
  border-top: 1px solid var(--border);
}

/* === Sections === */
.section { padding: 4rem 0; }
.section + .section { border-top: 1px solid var(--border); }

h2 {
  font-family: var(--font-heading);
  font-size: clamp(1.7rem, 3.5vw, 2.2rem);
  font-weight: 400;
  margin-bottom: 1.75rem;
}

.steps { display: flex; flex-direction: column; gap: 1.5rem; }
.step { display: flex; gap: 1rem; align-items: flex-start; }

.step-num {
  flex-shrink: 0;
  width: 32px; height: 32px;
  border-radius: 50%;
  border: 1.5px solid var(--border);
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-top: 2px;
}

.step strong { display: block; margin-bottom: 0.2rem; }
.step p { color: var(--text-muted); font-size: 0.95rem; }

.cta-section { padding: 3rem 0; }

/* === Footer === */
.footer { padding: 2.5rem 0; border-top: 1px solid var(--border); }

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

.footer-brand { font-family: var(--font-heading); font-size: 1rem; color: var(--text); }
.footer-sep { opacity: 0.3; }
.footer-highlight { color: var(--accent); }

/* === Responsive === */
@media (max-width: 768px) {
  .hero { padding: 2.5rem 0 2rem; }
  .hero-grid { grid-template-columns: 1fr; }
  .quotes-grid { grid-template-columns: 1fr; }
  .hero h1 { font-size: 1.8rem; }
  .install-cmd { font-size: 0.72rem; }
  .section { padding: 3rem 0; }
}
