/* ============================================
   Claude Code Skills — GitHub Primer Theme
   MkDocs Material custom properties override
   ============================================ */

/* ===========================================
   A. Light Mode — GitHub Primer Light
   =========================================== */
[data-md-color-scheme="default"] {
  --md-primary-fg-color: #0969da;
  --md-primary-fg-color--light: #218bff;
  --md-primary-fg-color--dark: #0550ae;
  --md-primary-bg-color: #ffffff;
  --md-primary-bg-color--light: #f6f8fa;
  --md-accent-fg-color: #0969da;
  --md-accent-fg-color--transparent: rgba(9, 105, 218, 0.1);

  --md-default-fg-color: #1f2328;
  --md-default-fg-color--light: #656d76;
  --md-default-fg-color--lighter: #8b949e;
  --md-default-fg-color--lightest: rgba(31, 35, 40, 0.12);
  --md-default-bg-color: #ffffff;
  --md-default-bg-color--light: #f6f8fa;
  --md-default-bg-color--lighter: #f6f8fa;
  --md-default-bg-color--lightest: #eaeef2;

  --md-code-fg-color: #1f2328;
  --md-code-bg-color: #f6f8fa;
  --md-code-hl-color: rgba(9, 105, 218, 0.1);

  --md-typeset-color: #1f2328;
  --md-typeset-a-color: #0969da;

  --md-footer-fg-color: #f0f6fc;
  --md-footer-fg-color--light: rgba(240, 246, 252, 0.7);
  --md-footer-fg-color--lighter: rgba(240, 246, 252, 0.4);
  --md-footer-bg-color: #24292f;
  --md-footer-bg-color--dark: #1c2128;
}

/* ===========================================
   B. Dark Mode — GitHub Primer Dark
   =========================================== */
[data-md-color-scheme="slate"] {
  --md-hue: 210;
  --md-primary-fg-color: #1f6feb;
  --md-primary-fg-color--light: #388bfd;
  --md-primary-fg-color--dark: #1158c7;
  --md-primary-bg-color: #0d1117;
  --md-primary-bg-color--light: #161b22;
  --md-accent-fg-color: #58a6ff;
  --md-accent-fg-color--transparent: rgba(31, 111, 235, 0.15);

  --md-default-fg-color: #f0f6fc;
  --md-default-fg-color--light: #c9d1d9;
  --md-default-fg-color--lighter: #8b949e;
  --md-default-fg-color--lightest: rgba(240, 246, 252, 0.1);
  --md-default-bg-color: #0d1117;
  --md-default-bg-color--light: #161b22;
  --md-default-bg-color--lighter: #161b22;
  --md-default-bg-color--lightest: #21262d;

  --md-code-fg-color: #c9d1d9;
  --md-code-bg-color: #161b22;
  --md-code-hl-color: rgba(31, 111, 235, 0.15);

  --md-typeset-color: #f0f6fc;
  --md-typeset-a-color: #58a6ff;

  --md-footer-fg-color: #f0f6fc;
  --md-footer-fg-color--light: rgba(240, 246, 252, 0.7);
  --md-footer-fg-color--lighter: rgba(240, 246, 252, 0.4);
  --md-footer-bg-color: #010409;
  --md-footer-bg-color--dark: #010409;
}

/* ===========================================
   C. Header & Navigation Bar
   =========================================== */
.md-header {
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
  box-shadow: none;
}

[data-md-color-scheme="default"] .md-header {
  background-color: #ffffff;
  color: #1f2328;
}

[data-md-color-scheme="slate"] .md-header {
  background-color: #161b22;
  color: #f0f6fc;
}

/* Header title color fix */
[data-md-color-scheme="default"] .md-header .md-header__title {
  color: #1f2328;
}

/* Header icons */
[data-md-color-scheme="default"] .md-header .md-icon {
  color: #656d76;
}

/* Tab bar */
.md-tabs {
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
}

[data-md-color-scheme="default"] .md-tabs {
  background-color: #ffffff;
}

[data-md-color-scheme="slate"] .md-tabs {
  background-color: #0d1117;
}

.md-tabs__link {
  font-weight: 500;
  font-size: 0.8rem;
  opacity: 0.7;
  transition: opacity 0.15s ease;
}

[data-md-color-scheme="default"] .md-tabs__link {
  color: #1f2328;
}

[data-md-color-scheme="slate"] .md-tabs__link {
  color: #c9d1d9;
}

.md-tabs__link:hover,
.md-tabs__link--active {
  opacity: 1;
}

/* ===========================================
   D. Sidebar Navigation
   =========================================== */
.md-nav {
  font-size: 0.74rem;
  line-height: 1.5;
}

.md-nav__item {
  padding: 0;
}

.md-nav__link {
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  margin: 1px 4px;
  font-weight: 400;
  transition: background-color 0.15s ease;
}

.md-nav__link:hover {
  background-color: var(--md-accent-fg-color--transparent);
}

.md-nav__link--active,
.md-nav__item .md-nav__link--active {
  font-weight: 600;
  color: var(--md-accent-fg-color);
  background-color: var(--md-accent-fg-color--transparent);
}

/* Section labels in sidebar */
.md-nav__item--nested > .md-nav__link {
  font-weight: 600;
  font-size: 0.68rem;
  letter-spacing: 0.03em;
  opacity: 0.8;
}

/* Sidebar scrollbar */
.md-sidebar__scrollwrap::-webkit-scrollbar {
  width: 4px;
}

.md-sidebar__scrollwrap::-webkit-scrollbar-thumb {
  background-color: var(--md-default-fg-color--lightest);
  border-radius: 4px;
}

/* ===========================================
   E. Buttons — GitHub-style
   =========================================== */
.md-typeset .md-button--primary {
  background-color: var(--md-primary-fg-color);
  color: #ffffff !important;
  border: 1px solid var(--md-primary-fg-color);
  border-radius: 8px;
  padding: 0.65rem 1.75rem;
  font-weight: 600;
  font-size: 0.9rem;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.1s ease, box-shadow 0.15s ease;
  box-shadow: 0 1px 3px rgba(9, 105, 218, 0.2);
}

.md-typeset .md-button--primary:hover {
  background-color: var(--md-primary-fg-color--dark);
  border-color: var(--md-primary-fg-color--dark);
  color: #ffffff !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(9, 105, 218, 0.25);
}

/* Outline / secondary button */
.md-typeset .md-button:not(.md-button--primary) {
  color: var(--md-primary-fg-color);
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 8px;
  padding: 0.65rem 1.75rem;
  font-weight: 600;
  font-size: 0.9rem;
  background-color: transparent;
  transition: background-color 0.15s ease, border-color 0.15s ease, transform 0.1s ease;
  box-shadow: none;
}

.md-typeset .md-button:not(.md-button--primary):hover {
  background-color: var(--md-accent-fg-color--transparent);
  border-color: var(--md-primary-fg-color);
  transform: translateY(-1px);
}

/* ===========================================
   F. Grid Cards
   =========================================== */
.md-typeset .grid.cards > ul > li,
.md-typeset .grid.cards > ol > li,
.md-typeset .grid > .card {
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 8px;
  background-color: var(--md-default-bg-color);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.04);
  transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.md-typeset .grid.cards > ul > li:hover,
.md-typeset .grid.cards > ol > li:hover,
.md-typeset .grid > .card:hover {
  border-color: var(--md-primary-fg-color--light);
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.08);
  transform: translateY(-2px);
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li,
[data-md-color-scheme="slate"] .md-typeset .grid.cards > ol > li {
  background-color: var(--md-default-bg-color--light);
}

[data-md-color-scheme="slate"] .md-typeset .grid.cards > ul > li:hover,
[data-md-color-scheme="slate"] .md-typeset .grid.cards > ol > li:hover {
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.3);
}

/* ===========================================
   G. Code Blocks
   =========================================== */
.md-typeset code {
  border-radius: 6px;
  border: 1px solid var(--md-default-fg-color--lightest);
  padding: 0.1em 0.35em;
  font-size: 0.85em;
}

.md-typeset pre {
  border-radius: 6px;
  border: 1px solid var(--md-default-fg-color--lightest);
}

.md-typeset pre > code {
  border: none;
  padding: 0;
}

/* ===========================================
   H. Tables
   =========================================== */
.md-typeset table:not([class]) {
  border: 1px solid var(--md-default-fg-color--lightest);
  border-radius: 6px;
  border-collapse: separate;
  border-spacing: 0;
  overflow: hidden;
}

.md-typeset table:not([class]) th {
  background-color: var(--md-default-bg-color--light);
  font-weight: 600;
  font-size: 0.78rem;
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
}

.md-typeset table:not([class]) td {
  border-top: 1px solid var(--md-default-fg-color--lightest);
}

/* ===========================================
   I. Admonitions
   =========================================== */
.md-typeset .admonition,
.md-typeset details {
  border-radius: 6px;
  box-shadow: none;
}

/* ===========================================
   J. Hero Section — High Impact Landing
   =========================================== */
.hero {
  text-align: center;
  padding: 3.5rem 1.5rem 2rem;
  max-width: 800px;
  margin: 0 auto;
}

/* Hero background gradient — subtle separation from content */
[data-md-color-scheme="default"] .md-content > .md-typeset > .hero {
  background: linear-gradient(180deg, #f0f6ff 0%, #ffffff 100%);
  border-radius: 16px;
  margin-top: 1rem;
  padding: 3rem 2rem 2rem;
}

[data-md-color-scheme="slate"] .md-content > .md-typeset > .hero {
  background: linear-gradient(180deg, rgba(31, 111, 235, 0.06) 0%, transparent 100%);
  border-radius: 16px;
  margin-top: 1rem;
  padding: 3rem 2rem 2rem;
}

.hero h1 {
  font-size: 3rem !important;
  font-weight: 800 !important;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin-bottom: 1rem !important;
  background: linear-gradient(135deg, #58a6ff 0%, #1f6feb 50%, #388bfd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-md-color-scheme="default"] .hero h1 {
  background: linear-gradient(135deg, #0550ae 0%, #0969da 50%, #218bff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1.15rem;
  opacity: 0.8;
  max-width: 540px;
  margin: 0 auto 1.25rem;
  line-height: 1.6;
}

.hero-platforms {
  font-size: 0.85rem;
  opacity: 0.55;
  margin-bottom: 1.75rem;
}

.hero .md-button {
  margin: 0.3rem;
}

/* Social proof — star count below hero */
.hero-social-proof {
  margin-top: 1.25rem;
  font-size: 0.85rem;
  opacity: 0.6;
  font-weight: 500;
}

/* ===========================================
   J2. Tools Bar
   =========================================== */
.tools-bar {
  text-align: center;
  padding: 1.5rem 1rem;
  max-width: 720px;
  margin: -0.5rem auto 0;
}

.tools-label {
  font-size: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
  opacity: 0.45;
  margin-bottom: 0.75rem;
  font-weight: 600;
}

.tools-grid {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.5rem;
}

.tool-badge {
  display: inline-block;
  padding: 0.35rem 0.75rem;
  border-radius: 6px;
  font-size: 0.8rem;
  font-weight: 600;
  text-decoration: none !important;
  transition: transform 0.15s ease, box-shadow 0.15s ease;
  border: 1px solid transparent;
}

.tool-badge:hover {
  transform: translateY(-1px);
  box-shadow: 0 2px 8px rgba(0,0,0,0.12);
  text-decoration: none !important;
}

/* Tool-specific colors */
.tool-claude { background: #D97706; color: #fff !important; }
.tool-codex { background: #10A37F; color: #fff !important; }
.tool-gemini { background: #4285F4; color: #fff !important; }
.tool-cursor { background: #000; color: #fff !important; }
.tool-aider { background: #6366F1; color: #fff !important; }
.tool-windsurf { background: #06B6D4; color: #fff !important; }
.tool-kilo { background: #EC4899; color: #fff !important; }
.tool-opencode { background: #8B5CF6; color: #fff !important; }
.tool-augment { background: #F59E0B; color: #fff !important; }
.tool-antigravity { background: #EF4444; color: #fff !important; }
.tool-openclaw { background: #059669; color: #fff !important; }

[data-md-color-scheme="default"] .tool-cursor {
  background: #1a1a1a;
}

[data-md-color-scheme="slate"] .tool-badge {
  border-color: rgba(255,255,255,0.1);
}

/* Skills page hero */
.skills-hero {
  text-align: center;
  padding: 2rem 1rem 0.5rem;
  max-width: 700px;
  margin: 0 auto;
}

.skills-hero h1 {
  font-size: 2.2rem !important;
  font-weight: 800 !important;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 0.5rem !important;
  background: linear-gradient(135deg, #58a6ff 0%, #1f6feb 50%, #388bfd 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-md-color-scheme="default"] .skills-hero h1 {
  background: linear-gradient(135deg, #0550ae 0%, #0969da 50%, #218bff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.skills-hero-sub {
  font-size: 1.05rem;
  opacity: 0.6;
  max-width: 520px;
  margin: 0 auto 1.5rem;
}

/* Skill count badge */
.skill-count {
  display: inline-block;
  background: var(--md-primary-fg-color);
  color: #ffffff;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 0.15rem 0.5rem;
  border-radius: 999px;
  vertical-align: middle;
  margin-left: 0.35rem;
}

/* ===========================================
   K. Typography — Improved Readability
   =========================================== */
.md-typeset {
  font-size: 0.82rem;
  line-height: 1.7;
}

.md-typeset h2 {
  font-weight: 700;
  font-size: 1.4em;
  letter-spacing: -0.02em;
  margin-top: 2.5rem;
  padding-bottom: 0.5rem;
  border-bottom: 1px solid var(--md-default-fg-color--lightest);
}

.md-typeset h2:first-of-type {
  margin-top: 1.5rem;
}

/* ===========================================
   L. Section Dividers — Visual Breathing Room
   =========================================== */
.md-typeset hr {
  border-color: var(--md-default-fg-color--lightest);
  margin: 3rem 0;
}

/* Alternating section backgrounds on homepage */
[data-md-color-scheme="default"] .md-typeset h2:nth-of-type(even) ~ .grid,
[data-md-color-scheme="default"] .md-typeset h2:nth-of-type(even) ~ ul {
  background-color: rgba(246, 248, 250, 0.5);
  border-radius: 12px;
  padding: 1rem;
  margin: 0 -1rem;
}

/* ===========================================
   M. Search Dialog
   =========================================== */
[data-md-color-scheme="default"] .md-search__form {
  background-color: #f6f8fa;
  border: 1px solid var(--md-default-fg-color--lightest);
}

/* ===========================================
   N. Announcement Bar
   =========================================== */
.md-banner {
  background-color: var(--md-primary-fg-color);
  color: #ffffff;
  font-size: 0.78rem;
}

.md-banner a {
  color: #ffffff;
}

/* ===========================================
   O. Page Metadata Bar (skills, agents, commands)
   =========================================== */
.page-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin: -0.25rem 0 1.25rem;
  font-size: 0.75rem;
}

.page-meta .meta-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.3rem;
  padding: 0.2rem 0.6rem;
  border-radius: 999px;
  border: 1px solid var(--md-default-fg-color--lightest);
  background-color: var(--md-default-bg-color--light);
  color: var(--md-default-fg-color--light);
  font-weight: 500;
  line-height: 1.4;
}

.page-meta .meta-badge code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.75rem;
  color: var(--md-default-fg-color);
}

.page-meta .meta-badge a {
  color: var(--md-typeset-a-color);
  text-decoration: none;
}

.page-meta .meta-badge a:hover {
  text-decoration: underline;
}

/* ===========================================
   P. Domain Index Cards
   =========================================== */
.domain-header {
  text-align: center;
  padding: 1.5rem 1rem 0.5rem;
  max-width: 640px;
  margin: 0 auto;
}

.domain-header h1 {
  font-size: 1.8rem !important;
  font-weight: 700 !important;
  letter-spacing: -0.02em;
  margin-bottom: 0.25rem !important;
}

.domain-header .domain-count {
  font-size: 1rem;
  opacity: 0.6;
  margin-bottom: 1rem;
}

/* ===========================================
   Q. Page Install Banner
   =========================================== */
.install-banner {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.65rem 1rem;
  border-radius: 6px;
  border: 1px solid var(--md-default-fg-color--lightest);
  background-color: var(--md-default-bg-color--light);
  font-size: 0.8rem;
  margin-bottom: 1.5rem;
}

.install-banner code {
  background: none;
  border: none;
  padding: 0;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--md-default-fg-color);
}

.install-banner .install-label {
  color: var(--md-default-fg-color--light);
  font-weight: 500;
  white-space: nowrap;
}

/* ===========================================
   R. Mobile Responsive
   =========================================== */
@media (max-width: 768px) {
  .hero h1 {
    font-size: 2rem !important;
  }

  .hero-subtitle {
    font-size: 1rem;
  }

  .hero {
    padding: 2rem 1rem 1.5rem;
  }

  [data-md-color-scheme="default"] .md-content > .md-typeset > .hero,
  [data-md-color-scheme="slate"] .md-content > .md-typeset > .hero {
    padding: 2rem 1rem 1.5rem;
    margin-top: 0.5rem;
  }

  .skills-hero h1 {
    font-size: 1.8rem !important;
  }

  .tools-bar {
    padding: 1rem 0.5rem;
  }

  .tool-badge {
    font-size: 0.7rem;
    padding: 0.25rem 0.55rem;
  }

  .page-meta {
    gap: 0.35rem;
  }

  .page-meta .meta-badge {
    font-size: 0.7rem;
    padding: 0.15rem 0.45rem;
  }

  .install-banner {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .domain-header h1 {
    font-size: 1.5rem !important;
  }
}
