/* AuthID SDK Documentation Styles */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700;800&family=JetBrains+Mono:wght@400;500&display=swap');

:root {
  --primary: #0066CC;
  --primary-dark: #004C99;
  --primary-light: #E6F0FA;
  --secondary: #00A3E0;
  --accent: #7AB800;
  --dark: #0F172A;
  --gray-900: #1E293B;
  --gray-800: #334155;
  --gray-700: #475569;
  --gray-600: #64748B;
  --gray-500: #94A3B8;
  --gray-400: #CBD5E1;
  --gray-300: #E2E8F0;
  --gray-200: #F1F5F9;
  --gray-100: #F8FAFC;
  --white: #FFFFFF;
  --error: #EF4444;
  --success: #10B981;
  --warning: #F59E0B;
  --info: #3B82F6;

  --sidebar-width: 280px;
  --header-height: 64px;
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-mono: 'JetBrains Mono', monospace;
}

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

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-sans);
  background: var(--gray-100);
  color: var(--gray-800);
  line-height: 1.6;
}

/* Header */
.header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--header-height);
  background: linear-gradient(135deg, #0066CC 0%, #00A3E0 100%);
  border-bottom: none;
  z-index: 100;
}

.header-content {
  max-width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 24px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 16px;
  text-decoration: none;
}

.logo img {
  height: 32px;
  /* Logo branca no fundo azul */
  filter: brightness(0) invert(1);
}

.logo-divider {
  width: 1px;
  height: 24px;
  background: rgba(255, 255, 255, 0.3);
}

.logo-text {
  font-size: 18px;
  font-weight: 700;
  color: var(--white);
}

.header-nav {
  display: flex;
  gap: 32px;
}

.header-nav a {
  color: rgba(255, 255, 255, 0.8);
  text-decoration: none;
  font-weight: 500;
  font-size: 14px;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}

.header-nav a:hover,
.header-nav a.active {
  color: var(--white);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 16px;
}

.version-badge {
  background: rgba(255, 255, 255, 0.2);
  color: var(--white);
  padding: 6px 12px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
}

.btn-primary {
  background: var(--white);
  color: var(--primary);
  padding: 10px 20px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 14px;
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 102, 204, 0.3);
}

/* Layout */
.layout {
  display: flex;
  padding-top: var(--header-height);
  min-height: 100vh;
}

/* Sidebar */
.sidebar {
  width: var(--sidebar-width);
  position: fixed;
  top: var(--header-height);
  left: 0;
  bottom: 0;
  background: var(--white);
  border-right: 1px solid var(--gray-300);
  padding: 24px 0;
  overflow-y: auto;
}

.sidebar-section {
  margin-bottom: 24px;
}

.sidebar-title {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray-500);
  padding: 0 24px;
  margin-bottom: 8px;
}

.sidebar-link {
  display: block;
  padding: 10px 24px;
  color: var(--gray-700);
  text-decoration: none;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  border-left: 3px solid transparent;
}

.sidebar-link:hover {
  background: var(--gray-100);
  color: var(--primary);
}

.sidebar-link.active {
  background: var(--primary-light);
  color: var(--primary);
  border-left-color: var(--primary);
}

.sidebar-footer {
  padding: 24px;
  margin-top: 40px;
  border-top: 1px solid var(--gray-200);
  text-align: center;
}

.sidebar-footer img {
  opacity: 0.7;
  margin-bottom: 8px;
  filter: invert(27%) sepia(95%) saturate(1642%) hue-rotate(196deg) brightness(96%) contrast(102%);
}

.sidebar-footer p {
  font-size: 11px;
  color: var(--gray-500);
}

/* Main Content */
.main-content {
  flex: 1;
  margin-left: var(--sidebar-width);
  padding: 40px 60px;
  max-width: calc(100% - var(--sidebar-width));
}

/* Hero Section */
.hero-section {
  background: linear-gradient(135deg, var(--dark) 0%, var(--gray-900) 100%);
  border-radius: 20px;
  padding: 60px;
  color: var(--white);
  margin-bottom: 60px;
}

.hero-badge {
  display: inline-block;
  background: rgba(0, 102, 204, 0.3);
  color: var(--secondary);
  padding: 6px 16px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  margin-bottom: 20px;
}

.hero-section h1 {
  font-size: 48px;
  font-weight: 800;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--white) 0%, var(--gray-400) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-description {
  font-size: 18px;
  color: var(--gray-400);
  max-width: 600px;
  margin-bottom: 40px;
}

.hero-features {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  margin-bottom: 40px;
}

.feature-card {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 24px;
  transition: all 0.2s;
}

.feature-card:hover {
  background: rgba(255, 255, 255, 0.1);
  transform: translateY(-4px);
}

.feature-icon {
  width: 48px;
  height: 48px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}

.feature-icon i {
  font-size: 20px;
  color: var(--white);
}

.feature-card h3 {
  font-size: 16px;
  font-weight: 600;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 13px;
  color: var(--gray-500);
}

/* Quick Install */
.quick-install {
  background: var(--gray-900);
  border-radius: 12px;
  overflow: hidden;
}

.install-tabs {
  display: flex;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.install-tab {
  background: none;
  border: none;
  padding: 12px 24px;
  color: var(--gray-500);
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
}

.install-tab.active {
  color: var(--white);
  background: rgba(255, 255, 255, 0.05);
}

.install-code {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
}

.install-code code {
  font-family: var(--font-mono);
  font-size: 14px;
  color: var(--accent);
}

.copy-btn {
  background: none;
  border: none;
  color: var(--gray-500);
  cursor: pointer;
  padding: 8px;
  transition: color 0.2s;
}

.copy-btn:hover {
  color: var(--white);
}

/* Doc Sections */
.doc-section {
  background: var(--white);
  border-radius: 16px;
  padding: 48px;
  margin-bottom: 32px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
}

.doc-section h2 {
  font-size: 28px;
  font-weight: 700;
  color: var(--dark);
  margin-bottom: 16px;
  padding-bottom: 16px;
  border-bottom: 2px solid var(--gray-200);
}

.doc-section h3 {
  font-size: 20px;
  font-weight: 600;
  color: var(--dark);
  margin: 32px 0 16px;
}

.doc-section h4 {
  font-size: 16px;
  font-weight: 600;
  color: var(--gray-700);
  margin: 24px 0 12px;
}

.doc-section p {
  color: var(--gray-600);
  margin-bottom: 16px;
}

/* Steps */
.step {
  display: flex;
  gap: 24px;
  margin-bottom: 32px;
}

.step-number {
  width: 40px;
  height: 40px;
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--white);
  font-weight: 700;
  flex-shrink: 0;
}

.step-content {
  flex: 1;
}

.step-content h3 {
  margin-top: 8px;
  margin-bottom: 16px;
}

/* Code Blocks */
pre {
  background: var(--dark);
  border-radius: 12px;
  padding: 24px;
  overflow-x: auto;
  margin: 16px 0;
}

pre code {
  font-family: var(--font-mono);
  font-size: 13px;
  line-height: 1.7;
}

code {
  font-family: var(--font-mono);
  font-size: 13px;
  background: var(--gray-200);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--primary-dark);
}

pre code {
  background: none;
  padding: 0;
  color: inherit;
}

/* Code Tabs */
.code-tabs {
  margin: 16px 0;
}

.code-tab-buttons {
  display: flex;
  gap: 4px;
  background: var(--gray-200);
  padding: 4px;
  border-radius: 8px 8px 0 0;
  width: fit-content;
}

.code-tab-btn {
  background: none;
  border: none;
  padding: 8px 16px;
  font-size: 13px;
  font-weight: 500;
  color: var(--gray-600);
  cursor: pointer;
  border-radius: 6px;
  transition: all 0.2s;
}

.code-tab-btn.active {
  background: var(--white);
  color: var(--dark);
}

.code-tab-content {
  display: none;
}

.code-tab-content.active {
  display: block;
}

.code-tab-content pre {
  margin-top: 0;
  border-radius: 0 12px 12px 12px;
}

/* Requirements List */
.requirements-list {
  list-style: none;
  margin: 16px 0;
}

.requirements-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  border-bottom: 1px solid var(--gray-200);
  color: var(--gray-700);
}

.requirements-list li i {
  color: var(--primary);
  font-size: 18px;
  width: 24px;
}

/* Callout */
.callout {
  display: flex;
  gap: 16px;
  padding: 20px;
  border-radius: 12px;
  margin: 24px 0;
}

.callout i {
  font-size: 20px;
  flex-shrink: 0;
}

.callout-info {
  background: #EFF6FF;
  border: 1px solid #BFDBFE;
}

.callout-info i {
  color: var(--info);
}

.callout-warning {
  background: #FFFBEB;
  border: 1px solid #FDE68A;
}

.callout-warning i {
  color: var(--warning);
}

.callout strong {
  display: block;
  margin-bottom: 4px;
  color: var(--dark);
}

/* Props Table */
.props-table {
  margin: 24px 0;
  overflow-x: auto;
}

.props-table table {
  width: 100%;
  border-collapse: collapse;
}

.props-table th,
.props-table td {
  padding: 14px 16px;
  text-align: left;
  border-bottom: 1px solid var(--gray-200);
}

.props-table th {
  background: var(--gray-100);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--gray-600);
}

.props-table td {
  font-size: 14px;
}

.props-table code {
  font-size: 12px;
}

.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 12px;
  font-size: 11px;
  font-weight: 600;
}

.badge.required {
  background: #FEE2E2;
  color: var(--error);
}

.badge.optional {
  background: var(--gray-200);
  color: var(--gray-600);
}

/* Flow Diagram */
.flow-diagram {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  padding: 40px 20px;
  background: var(--gray-100);
  border-radius: 12px;
  margin: 24px 0;
  overflow-x: auto;
}

.flow-step {
  text-align: center;
  flex-shrink: 0;
}

.flow-icon {
  width: 56px;
  height: 56px;
  background: var(--white);
  border: 2px solid var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 12px;
}

.flow-icon i {
  font-size: 20px;
  color: var(--primary);
}

.flow-label {
  font-size: 12px;
  font-weight: 500;
  color: var(--gray-700);
  white-space: nowrap;
}

.flow-arrow {
  color: var(--gray-400);
  flex-shrink: 0;
}

/* Credential Types */
.credential-types {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 16px;
  margin: 24px 0;
}

.credential-type {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  background: var(--gray-100);
  border-radius: 10px;
  transition: all 0.2s;
}

.credential-type:hover {
  background: var(--primary-light);
}

.credential-type i {
  font-size: 24px;
  color: var(--primary);
}

.credential-type span {
  font-weight: 500;
  color: var(--gray-700);
}

/* API Section */
.api-section {
  margin: 32px 0;
  padding: 24px;
  background: var(--gray-50);
  border-radius: 12px;
  border: 1px solid var(--gray-200);
}

.api-title {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 12px !important;
  margin-top: 0 !important;
}

.method-badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 6px;
  font-size: 11px;
  font-weight: 700;
  font-family: var(--font-mono);
}

.method-badge.get {
  background: #DBEAFE;
  color: #1D4ED8;
}

.method-badge.post {
  background: #D1FAE5;
  color: #047857;
}

.method-badge.put {
  background: #FEF3C7;
  color: #B45309;
}

.method-badge.delete {
  background: #FEE2E2;
  color: #B91C1C;
}

.method-list {
  margin: 16px 0;
}

.method-item {
  padding: 16px;
  border-bottom: 1px solid var(--gray-200);
}

.method-item:last-child {
  border-bottom: none;
}

.method-item code {
  display: block;
  background: var(--dark);
  color: var(--accent);
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 8px;
}

.method-item p {
  margin: 0;
  font-size: 14px;
  color: var(--gray-600);
}

/* Error Codes */
.error-codes {
  margin: 24px 0;
}

.error-code {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--gray-200);
}

.error-code code {
  background: #FEE2E2;
  color: var(--error);
  min-width: 200px;
}

.error-code span {
  color: var(--gray-600);
  font-size: 14px;
}

/* Footer */
.doc-footer {
  padding: 40px;
  text-align: center;
  border-top: 1px solid var(--gray-200);
  margin-top: 60px;
}

.footer-links {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 24px;
}

.footer-links a {
  color: var(--gray-600);
  text-decoration: none;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 8px;
  transition: color 0.2s;
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-brand {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}

.footer-brand p {
  font-size: 13px;
  color: var(--gray-500);
  margin: 0;
}

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

@media (max-width: 768px) {
  .sidebar {
    display: none;
  }

  .main-content {
    margin-left: 0;
    padding: 24px;
    max-width: 100%;
  }

  .hero-section {
    padding: 32px;
  }

  .hero-section h1 {
    font-size: 32px;
  }

  .hero-features {
    grid-template-columns: 1fr;
  }

  .doc-section {
    padding: 24px;
  }

  .credential-types {
    grid-template-columns: 1fr;
  }

  .flow-diagram {
    flex-direction: column;
  }

  .flow-arrow {
    transform: rotate(90deg);
  }
}

/* Scrollbar */
::-webkit-scrollbar {
  width: 8px;
  height: 8px;
}

::-webkit-scrollbar-track {
  background: var(--gray-100);
}

::-webkit-scrollbar-thumb {
  background: var(--gray-400);
  border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
  background: var(--gray-500);
}

/* Animations */
@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.doc-section {
  animation: fadeIn 0.5s ease-out;
}

/* Selection */
::selection {
  background: var(--primary-light);
  color: var(--primary-dark);
}
