Skip to content

UniFace: A Unified Face Analysis Library for Python | Detection, alignment, landmarks, face-mesh, recognition, parsing, gaze, attributes and anti-spoofing under one API.

5.3 KB
Raw Blame
/* UniFace Documentation - Custom Styles */

/* ===== Announcement Bar ===== */

/* Light theme: indigo gradient, white text. */
[data-md-color-scheme="default"] .md-banner {
  background: linear-gradient(90deg, #3f51b5 0%, #7c4dff 100%);
  color: #ffffff;
}

[data-md-color-scheme="default"] .md-banner a {
  color: #ffffff;
  text-decoration: none;
}

[data-md-color-scheme="default"] .md-banner a:hover {
  text-decoration: underline;
}

[data-md-color-scheme="default"] .md-banner .twemoji svg {
  fill: #ffd54f;
}

/* Dark theme: deeper purple gradient, soft gold star. */
[data-md-color-scheme="slate"] .md-banner {
  background: linear-gradient(90deg, #4527a0 0%, #7c4dff 100%);
  color: #ffffff;
}

[data-md-color-scheme="slate"] .md-banner a {
  color: #ffffff;
  text-decoration: none;
}

[data-md-color-scheme="slate"] .md-banner a:hover {
  text-decoration: underline;
}

[data-md-color-scheme="slate"] .md-banner .twemoji svg {
  fill: #ffd54f;
}

/* ===== Hero Section ===== */

.md-content .hero {
  text-align: center;
  padding: 3rem 1rem 2rem;
  margin: 0 auto;
  max-width: 900px;
}

.hero-title {
  font-size: 3.5rem !important;
  font-weight: 800 !important;
  margin-bottom: 0.5rem !important;
  background: linear-gradient(135deg, var(--md-primary-fg-color) 0%, #7c4dff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 1rem;
  color: var(--md-default-fg-color--light);
  margin-bottom: 1.5rem !important;
  font-weight: 400;
  letter-spacing: 0.5px;
}

.hero .md-button {
  margin: 0.5rem 0.25rem;
  padding: 0.6rem 1.25rem;
  font-weight: 500;
  font-size: 0.9rem;
  border-radius: 6px;
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.hero .md-button .twemoji,
.hero .md-button svg {
  width: 1em;
  height: 1em;
  fill: currentColor;
}

.hero .md-button--primary {
  background: var(--md-primary-fg-color);
  border: 1px solid var(--md-primary-fg-color);
  color: #ffffff;
}

.hero .md-button--primary:hover {
  background: var(--md-primary-fg-color--dark, #303f9f);
  border-color: var(--md-primary-fg-color--dark, #303f9f);
  color: #ffffff;
}

.hero .md-button:not(.md-button--primary) {
  background: transparent;
  border: 1px solid var(--md-default-fg-color--lighter);
  color: var(--md-default-fg-color);
}

.hero .md-button:not(.md-button--primary):hover {
  background: var(--md-default-fg-color--lightest);
  border-color: var(--md-default-fg-color--light);
  color: var(--md-default-fg-color);
}

/* Badge styling in hero */
.hero p a img {
  margin: 0 3px;
  height: 24px !important;
}

/* ===== Feature Grid ===== */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.25rem;
  margin: 2rem 0;
}

.feature-card {
  padding: 1.5rem;
  border-radius: 12px;
  background: var(--md-code-bg-color);
  border: 1px solid var(--md-default-fg-color--lightest);
  position: relative;
  transition: border-color 0.2s ease;
}

.feature-card:hover {
  border-color: var(--md-accent-fg-color);
}

/* Transparent overlay link — makes the whole card clickable. */
.feature-card-link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
  text-decoration: none;
}

.feature-card h3 {
  margin-top: 0 !important;
  margin-bottom: 0.75rem !important;
  font-size: 1rem !important;
  font-weight: 600;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.feature-card p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--md-default-fg-color--light);
  line-height: 1.5;
}

/* ===== Next Steps Grid (2 columns) ===== */
.next-steps-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1.25rem;
  margin: 2rem 0;
}

.next-steps-grid .feature-card {
  padding: 2rem;
}

.next-steps-grid .feature-card h3 {
  font-size: 1.1rem !important;
}

/* ===== Dark Mode Adjustments ===== */
[data-md-color-scheme="slate"] .hero-title {
  background: linear-gradient(135deg, #7c4dff 0%, #b388ff 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

[data-md-color-scheme="slate"] .hero .md-button--primary {
  background: #ffffff;
  border-color: #ffffff;
  color: #1a1a2e;
}

[data-md-color-scheme="slate"] .hero .md-button--primary:hover {
  background: #e6e6e6;
  border-color: #e6e6e6;
  color: #1a1a2e;
}

[data-md-color-scheme="slate"] .hero .md-button:not(.md-button--primary) {
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.25);
  color: rgba(255, 255, 255, 0.9);
}

[data-md-color-scheme="slate"] .hero .md-button:not(.md-button--primary):hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.4);
  color: #ffffff;
}

/* ===== Responsive Design ===== */
@media (max-width: 1200px) {
  .feature-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .hero-title {
    font-size: 2.5rem !important;
  }

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

  .feature-grid,
  .next-steps-grid {
    grid-template-columns: 1fr;
  }

  .hero .md-button {
    display: block;
    margin: 0.5rem auto;
    max-width: 200px;
  }
}

@media (max-width: 480px) {
  .hero-title {
    font-size: 2rem !important;
  }

  .feature-card {
    padding: 1.25rem;
  }
}