@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;600;800&family=JetBrains+Mono:wght@400;600&family=Poppins:wght@700&display=swap');

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background: #0d1117;
  color: #e6edf3;
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.7;
}

/* Back button */
.back-button {
  position: fixed;
  top: 20px;
  right: 20px;
  width: 36px;
  height: 36px;
  background-color: #21262d;
  color: #e6edf3;
  border-radius: 50%;
  text-decoration: none;
  z-index: 10000;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.2s ease;
  border: 1px solid #30363d;
}

.back-button:hover {
  background-color: #30363d;
}

/* Wrapper */
.spec-wrapper {
  max-width: 840px;
  margin: 0 auto;
  padding: 80px 24px 120px;
}

/* ── Header ── */
.spec-header {
  margin-bottom: 80px;
}

.spec-header-title {
  font-size: clamp(2.5rem, 6vw, 3.5rem);
  font-weight: 800;
  color: #ffffff;
  line-height: 1.1;
  margin-bottom: 16px;
}

.spec-header-desc {
  font-size: 1.05rem;
  color: rgba(255, 255, 255, 0.55);
  line-height: 1.7;
  max-width: 520px;
}

/* ── Section ── */
.spec-section {
  margin-bottom: 80px;
}

.spec-section-title {
  font-size: 0.72rem;
  font-weight: 700;
  color: #4CAF50;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: 36px;
  display: flex;
  align-items: center;
  gap: 14px;
}

.spec-section-title::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #21262d;
}

.spec-subsection {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.3);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin: 32px 0 14px;
}

/* ── Colors ── */
.color-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 10px;
}

.color-swatch {
  border-radius: 8px;
  overflow: hidden;
  border: 1px solid #21262d;
}

.swatch-block {
  height: 60px;
}

.swatch-info {
  padding: 10px 12px;
  background: #161b22;
}

.swatch-name {
  display: block;
  font-size: 0.75rem;
  font-weight: 600;
  color: #e6edf3;
  margin-bottom: 3px;
}

.swatch-hex {
  display: block;
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.65rem;
  color: rgba(255, 255, 255, 0.35);
}

/* ── Typography ── */
.type-entry {
  padding: 36px 0 28px;
  border-bottom: 1px solid #161b22;
}

.type-entry:first-child {
  border-top: 1px solid #161b22;
}

.type-example {
  margin-bottom: 14px;
  word-break: break-word;
}

.type-spec-bar {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}

.type-spec-name {
  font-size: 0.78rem;
  font-weight: 700;
  color: #ffffff;
}

.type-spec-dot {
  font-size: 0.72rem;
  color: rgba(255, 255, 255, 0.2);
}

.type-spec-detail {
  font-size: 0.75rem;
  color: rgba(255, 255, 255, 0.4);
}

/* ── Components ── */
.component-group {
  margin-bottom: 40px;
}

.component-label {
  font-size: 0.72rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.35);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 16px;
}

.component-row {
  display: flex;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

/* Primary button */
.demo-btn-primary {
  display: inline-flex;
  align-items: center;
  padding: 10px 40px;
  font-size: 1rem;
  font-weight: 600;
  color: #ffffff;
  background-color: #4CAF50;
  border: none;
  border-radius: 50px;
  cursor: default;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
}

/* Secondary button */
.demo-btn-secondary {
  display: inline-flex;
  align-items: center;
  padding: 10px 40px;
  font-size: 1rem;
  font-weight: 600;
  color: #4CAF50;
  background: transparent;
  border: 1px solid #4CAF50;
  border-radius: 50px;
  cursor: default;
  text-decoration: none;
  font-family: 'Inter', sans-serif;
}

/* Skill CTA primary */
.demo-cta-primary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: #4CAF50;
  color: #0d1117;
  font-weight: 700;
  font-size: 0.9rem;
  border-radius: 6px;
  text-decoration: none;
  cursor: default;
  font-family: 'Inter', sans-serif;
}

/* Skill CTA secondary */
.demo-cta-secondary {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 12px 28px;
  background: transparent;
  color: #e6edf3;
  font-weight: 600;
  font-size: 0.9rem;
  border-radius: 6px;
  border: 1px solid #30363d;
  text-decoration: none;
  cursor: default;
  font-family: 'Inter', sans-serif;
}

/* Back button demo */
.demo-back {
  width: 36px;
  height: 36px;
  background-color: #21262d;
  color: #e6edf3;
  border-radius: 50%;
  font-size: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  border: 1px solid #30363d;
  cursor: default;
}

/* Skill card demo */
.demo-skill-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 24px 28px;
  border-radius: 16px;
  border: 1px solid rgba(76, 175, 80, 0.5);
  background: transparent;
  width: 240px;
  cursor: default;
}

.demo-skill-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: #ffffff;
}

.demo-skill-card-desc {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.6);
  line-height: 1.5;
}

/* Project card demo */
.demo-project-card {
  width: 220px;
  border-radius: 12px;
  overflow: hidden;
  background: #161b22;
  border: 1px solid #21262d;
  cursor: default;
}

.demo-project-card-img {
  width: 100%;
  height: 120px;
  background: #21262d;
  display: flex;
  align-items: center;
  justify-content: center;
  color: rgba(255, 255, 255, 0.2);
  font-size: 0.72rem;
}

.demo-project-card-body {
  padding: 14px 16px;
}

.demo-project-card-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #e6edf3;
  margin-bottom: 4px;
}

.demo-project-card-sub {
  font-size: 0.78rem;
  color: rgba(255, 255, 255, 0.35);
}

/* Tags */
.demo-tag-skill {
  font-family: 'JetBrains Mono', monospace;
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 4px;
  border: 1px solid rgba(76, 175, 80, 0.4);
  color: #4CAF50;
  background: rgba(76, 175, 80, 0.06);
}

.demo-tag-project {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 4px;
  background: rgba(76, 175, 80, 0.15);
  color: #4CAF50;
}

/* Section label pattern */
.demo-section-label {
  font-size: 0.72rem;
  font-weight: 700;
  color: #4CAF50;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}

.demo-section-label::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #21262d;
}

/* Progress bar */
.demo-progress-bar {
  height: 2px;
  background: #4CAF50;
  border-radius: 1px;
}

/* ── Layout ── */
.layout-row {
  display: grid;
  grid-template-columns: 160px 1fr;
  gap: 16px;
  padding: 16px 0;
  border-bottom: 1px solid #161b22;
  align-items: start;
}

.layout-row:first-child {
  border-top: 1px solid #161b22;
}

.layout-key {
  font-size: 0.78rem;
  font-weight: 600;
  color: #ffffff;
  padding-top: 2px;
}

.layout-value {
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.5);
  line-height: 1.8;
}

@media (max-width: 600px) {
  .color-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .layout-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .type-spec-bar {
    gap: 4px;
  }
}
