/* UCF FlowEngine — Design System
   Dark theme matching ucfflowengine.com + CEO Dashboard */

:root {
  --bg-primary: #0b0d12;
  --bg-card: #121721;
  --bg-card-hover: #1a2030;
  --bg-input: #0d1117;
  --border: #1e2736;
  --border-focus: #9fd2ff;

  --text-primary: #e9edf5;
  --text-muted: #aeb7c7;
  --text-dim: #6b7a90;

  --accent-blue: #9fd2ff;
  --accent-blue-dim: rgba(159, 210, 255, 0.15);
  --accent-green: #b4e1a7;
  --accent-green-bright: #22c55e;
  --accent-red: #ef4444;
  --accent-yellow: #fbbf24;

  --font-stack: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
  --font-mono: ui-monospace, 'SF Mono', 'Cascadia Code', 'Fira Code', monospace;

  --radius: 14px;
  --radius-sm: 8px;
  --max-width: 1100px;
  --transition: 0.2s ease;
}

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

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

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

a {
  color: var(--accent-blue);
  text-decoration: none;
  transition: opacity var(--transition);
}

a:hover {
  opacity: 0.8;
}

/* Layout */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

.page {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-content {
  flex: 1;
  padding: 60px 0 80px;
}

/* Header */
.site-header {
  padding: 20px 0;
  border-bottom: 1px solid var(--border);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  letter-spacing: -0.02em;
}

.logo-mark {
  width: 32px;
  height: 32px;
  background: linear-gradient(135deg, var(--accent-blue), #6ba3d6);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 0.75rem;
  color: var(--bg-primary);
}

.header-nav {
  display: flex;
  gap: 24px;
  align-items: center;
}

.header-nav a {
  color: var(--text-muted);
  font-size: 0.9rem;
  transition: color var(--transition);
}

.header-nav a:hover {
  color: var(--text-primary);
  opacity: 1;
}

/* Footer */
.site-footer {
  padding: 24px 0;
  border-top: 1px solid var(--border);
  text-align: center;
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* Cards */
.card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
  transition: transform var(--transition), border-color var(--transition);
}

.card:hover {
  transform: translateY(-1px);
  border-color: rgba(159, 210, 255, 0.25);
}

.card-header {
  margin-bottom: 16px;
}

.card-title {
  font-size: 1.15rem;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.card-subtitle {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-top: 4px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 28px;
  border: none;
  border-radius: var(--radius-sm);
  font-family: var(--font-stack);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn:hover {
  opacity: 1;
}

.btn-primary {
  background: var(--accent-blue);
  color: var(--bg-primary);
}

.btn-primary:hover {
  background: #b8dfff;
  transform: translateY(-1px);
}

.btn-primary:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

.btn-secondary {
  background: transparent;
  color: var(--accent-blue);
  border: 1px solid var(--accent-blue);
}

.btn-secondary:hover {
  background: var(--accent-blue-dim);
}

.btn-success {
  background: var(--accent-green-bright);
  color: #fff;
}

.btn-success:hover {
  background: #16a34a;
}

.btn-lg {
  padding: 16px 40px;
  font-size: 1.05rem;
}

/* Forms */
input, select, textarea {
  font-family: var(--font-stack);
  font-size: 0.95rem;
  padding: 12px 16px;
  background: var(--bg-input);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text-primary);
  width: 100%;
  transition: border-color var(--transition);
}

input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--border-focus);
}

label {
  display: block;
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-bottom: 6px;
  font-weight: 500;
}

/* Hero */
.hero {
  text-align: center;
  padding: 80px 0 60px;
}

.hero h1 {
  font-size: 2.8rem;
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.15;
  margin-bottom: 16px;
}

.hero h1 span {
  color: var(--accent-blue);
}

.hero p {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 600px;
  margin: 0 auto 32px;
}

/* Steps */
.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
  margin: 40px 0;
}

.step {
  text-align: center;
  padding: 24px 16px;
}

.step-number {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: var(--accent-blue-dim);
  color: var(--accent-blue);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 700;
  font-size: 1.1rem;
  margin-bottom: 16px;
}

.step h3 {
  font-size: 1rem;
  font-weight: 600;
  margin-bottom: 8px;
}

.step p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

/* Pricing */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 24px;
  margin: 40px 0;
}

.pricing-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 32px;
  text-align: center;
}

.pricing-card.featured {
  border-color: var(--accent-blue);
  position: relative;
}

.pricing-badge {
  position: absolute;
  top: -12px;
  left: 50%;
  transform: translateX(-50%);
  background: var(--accent-blue);
  color: var(--bg-primary);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 4px 16px;
  border-radius: 20px;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.pricing-price {
  font-size: 2.5rem;
  font-weight: 700;
  margin: 16px 0 8px;
}

.pricing-price span {
  font-size: 1rem;
  color: var(--text-muted);
  font-weight: 400;
}

.pricing-desc {
  color: var(--text-muted);
  margin-bottom: 24px;
  font-size: 0.95rem;
}

.pricing-features {
  list-style: none;
  text-align: left;
  margin-bottom: 28px;
}

.pricing-features li {
  padding: 8px 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.pricing-features li::before {
  content: "\2713";
  color: var(--accent-green);
  font-weight: 700;
  flex-shrink: 0;
}

/* Progress Stepper */
.stepper {
  display: flex;
  justify-content: center;
  gap: 0;
  margin: 40px 0;
  overflow-x: auto;
}

.stepper-step {
  display: flex;
  align-items: center;
  gap: 0;
}

.stepper-dot {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-card);
  border: 2px solid var(--border);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-dim);
  flex-shrink: 0;
  transition: all 0.3s ease;
}

.stepper-step.active .stepper-dot {
  border-color: var(--accent-blue);
  background: var(--accent-blue-dim);
  color: var(--accent-blue);
}

.stepper-step.complete .stepper-dot {
  border-color: var(--accent-green-bright);
  background: var(--accent-green-bright);
  color: #fff;
}

.stepper-step.complete .stepper-dot::after {
  content: "\2713";
}

.stepper-line {
  width: 40px;
  height: 2px;
  background: var(--border);
  flex-shrink: 0;
}

.stepper-step.complete + .stepper-step .stepper-line,
.stepper-step.complete .stepper-line {
  background: var(--accent-green-bright);
}

.stepper-label {
  display: block;
  font-size: 0.75rem;
  color: var(--text-dim);
  text-align: center;
  margin-top: 8px;
  white-space: nowrap;
}

.stepper-step.active .stepper-label {
  color: var(--accent-blue);
}

.stepper-step.complete .stepper-label {
  color: var(--accent-green);
}

/* Upload Zone */
.upload-zone {
  border: 2px dashed var(--border);
  border-radius: var(--radius);
  padding: 48px 24px;
  text-align: center;
  cursor: pointer;
  transition: all var(--transition);
}

.upload-zone:hover,
.upload-zone.dragover {
  border-color: var(--accent-blue);
  background: var(--accent-blue-dim);
}

.upload-zone h3 {
  margin-bottom: 8px;
}

.upload-zone p {
  color: var(--text-muted);
  font-size: 0.9rem;
}

.upload-icon {
  font-size: 2rem;
  margin-bottom: 12px;
  opacity: 0.6;
}

/* Progress Bar */
.progress-bar {
  width: 100%;
  height: 8px;
  background: var(--bg-input);
  border-radius: 4px;
  overflow: hidden;
  margin: 16px 0;
}

.progress-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent-blue), var(--accent-green-bright));
  border-radius: 4px;
  transition: width 0.3s ease;
  width: 0%;
}

.progress-text {
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* Status Badge */
.badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: 20px;
  font-size: 0.8rem;
  font-weight: 600;
}

.badge-success {
  background: rgba(34, 197, 94, 0.15);
  color: var(--accent-green-bright);
}

.badge-pending {
  background: rgba(251, 191, 36, 0.15);
  color: var(--accent-yellow);
}

.badge-error {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.badge-info {
  background: var(--accent-blue-dim);
  color: var(--accent-blue);
}

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

.artifact-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  margin-bottom: 8px;
  transition: border-color var(--transition);
}

.artifact-item:hover {
  border-color: rgba(159, 210, 255, 0.25);
}

.artifact-name {
  font-family: var(--font-mono);
  font-size: 0.9rem;
}

.artifact-size {
  color: var(--text-dim);
  font-size: 0.85rem;
}

/* Alert */
.alert {
  padding: 16px 20px;
  border-radius: var(--radius-sm);
  margin: 16px 0;
  font-size: 0.9rem;
}

.alert-info {
  background: var(--accent-blue-dim);
  border: 1px solid rgba(159, 210, 255, 0.2);
  color: var(--accent-blue);
}

.alert-success {
  background: rgba(34, 197, 94, 0.1);
  border: 1px solid rgba(34, 197, 94, 0.2);
  color: var(--accent-green);
}

.alert-error {
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.2);
  color: var(--accent-red);
}

/* Section */
.section {
  margin: 60px 0;
}

.section-title {
  text-align: center;
  font-size: 1.8rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 12px;
}

.section-subtitle {
  text-align: center;
  color: var(--text-muted);
  font-size: 1rem;
  margin-bottom: 40px;
}

/* Spinner */
.spinner {
  width: 24px;
  height: 24px;
  border: 3px solid var(--border);
  border-top-color: var(--accent-blue);
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  display: inline-block;
}

@keyframes spin {
  to { transform: rotate(360deg); }
}

/* Message Pages */
.message-page {
  text-align: center;
  padding: 100px 24px;
}

.message-icon {
  font-size: 3rem;
  margin-bottom: 24px;
}

.message-page h1 {
  font-size: 1.8rem;
  margin-bottom: 12px;
}

.message-page p {
  color: var(--text-muted);
  margin-bottom: 32px;
  max-width: 480px;
  margin-left: auto;
  margin-right: auto;
}

/* Utilities */
.text-center { text-align: center; }
.text-muted { color: var(--text-muted); }
.text-dim { color: var(--text-dim); }
.text-blue { color: var(--accent-blue); }
.text-green { color: var(--accent-green); }
.mt-1 { margin-top: 8px; }
.mt-2 { margin-top: 16px; }
.mt-3 { margin-top: 24px; }
.mt-4 { margin-top: 32px; }
.mb-2 { margin-bottom: 16px; }
.mb-3 { margin-bottom: 24px; }
.gap-2 { gap: 16px; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.hidden { display: none !important; }

/* Blog / Article */
.article-meta {
  color: var(--text-dim);
  font-size: 0.85rem;
  display: flex;
  gap: 16px;
  align-items: center;
  padding-bottom: 24px;
  border-bottom: 1px solid var(--border);
}

.article-body {
  font-size: 1.05rem;
  line-height: 1.8;
  max-width: 720px;
}

.article-body h2 {
  font-size: 1.4rem;
  margin: 40px 0 16px;
  letter-spacing: -0.01em;
}

.article-body h3 {
  font-size: 1.15rem;
  margin: 32px 0 12px;
}

.article-body p {
  margin-bottom: 16px;
  color: var(--text-muted);
}

.article-body a {
  color: var(--accent-blue);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.article-body blockquote {
  border-left: 3px solid var(--accent-blue);
  padding: 12px 20px;
  margin: 24px 0;
  background: var(--bg-card);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  color: var(--text-muted);
  font-style: italic;
}

.article-body code {
  font-family: var(--font-mono);
  font-size: 0.9em;
  background: var(--bg-card);
  padding: 2px 6px;
  border-radius: 4px;
  color: var(--accent-blue);
}

.article-body ul, .article-body ol {
  margin: 16px 0;
  padding-left: 24px;
  color: var(--text-muted);
}

.article-body li {
  margin-bottom: 8px;
}

.blog-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 24px;
}

/* Homepage hero actions */
.hero-actions {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.hero-tertiary {
  font-size: 0.9rem;
}

.hero-tertiary a {
  color: var(--text-muted);
}

/* Scope exclusion list (red X instead of green check) */
.scope-excluded li::before {
  content: "\2717";
  color: var(--accent-red);
}

/* Responsive */
@media (max-width: 768px) {
  .hero h1 { font-size: 2rem; }
  .hero-actions { flex-direction: column; align-items: center; }
  .pricing-grid { grid-template-columns: 1fr; }
  .steps { grid-template-columns: 1fr; }
  .stepper { flex-wrap: wrap; justify-content: flex-start; }
  .blog-grid { grid-template-columns: 1fr; }
}
