/* State Profile Styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

:root {
  --bg: #0c0c0c;
  --bg-card: #141414;
  --bg-hover: #1a1a1a;
  --text: #f8fafc;
  --text-secondary: #94a3b8;
  --text-muted: #64748b;
  --border: rgba(255, 255, 255, 0.08);
  --accent: #3b82f6;
  --accent-hover: #2563eb;
  --green: #10b981;
  --orange: #f59e0b;
}

body {
  font-family:
    'Inter',
    -apple-system,
    BlinkMacSystemFont,
    sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 100px 24px 48px;
}

.loading {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 60vh;
  color: var(--text-muted);
}

.error {
  text-align: center;
  padding: 48px;
  color: var(--text-muted);
}
.error h1 {
  color: var(--text);
  margin-bottom: 16px;
}
.error a {
  color: var(--accent);
  text-decoration: none;
}
.error a:hover {
  text-decoration: underline;
}

/* State Header */
.state-header {
  display: flex;
  gap: 20px;
  margin-bottom: 24px;
  align-items: flex-start;
}

.state-favicon {
  width: 64px;
  height: 64px;
  background: var(--bg-card);
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border: 1px solid var(--border);
  overflow: hidden;
}

.state-favicon img {
  width: 48px;
  height: 48px;
  object-fit: contain;
}
.state-info h1 {
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 12px;
}

.stat-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stat-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
}

.stat-badge.companies {
  background: rgba(59, 130, 246, 0.1);
  color: var(--accent);
}
.stat-badge.schools {
  background: rgba(16, 185, 129, 0.1);
  color: var(--green);
}
.stat-badge.departments {
  background: rgba(245, 158, 11, 0.1);
  color: var(--orange);
}
.stat-badge.programs {
  background: rgba(168, 85, 247, 0.1);
  color: #a855f7;
}

/* Quick Links Bar */
.quick-links {
  display: flex;
  gap: 12px;
  margin-bottom: 32px;
  flex-wrap: wrap;
}

.btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 14px;
  font-weight: 500;
  text-decoration: none;
  transition: all 0.2s;
  border: none;
  cursor: pointer;
}

.btn-primary {
  background: var(--accent);
  color: white;
}
.btn-primary:hover {
  background: var(--accent-hover);
}
.btn-secondary {
  background: var(--bg-card);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover {
  background: var(--bg-hover);
}

/* Grid Layout */
.profile-grid {
  display: grid;
  grid-template-columns: 2fr 1fr;
  gap: 24px;
}

/* Cards */
.card {
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border);
  padding: 24px;
  margin-bottom: 24px;
}

.card-title {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin-bottom: 16px;
}

/* Department & Program Lists */
.dept-list,
.program-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.dept-item,
.program-item {
  padding: 12px 16px;
  background: var(--bg-hover);
  border-radius: 8px;
  border: 1px solid var(--border);
}

.dept-item-name,
.program-item-name {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 4px;
}

.dept-item-desc,
.program-item-desc {
  font-size: 13px;
  color: var(--text-secondary);
}

.dept-item a {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
}
.dept-item a:hover {
  text-decoration: underline;
}

/* Contact List */
.contact-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.contact-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}
.contact-item:last-child {
  border-bottom: none;
}
.contact-item-name {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 2px;
}
.contact-item-role {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 4px;
}
.contact-item a {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
}
.contact-item a:hover {
  text-decoration: underline;
}

/* Registry List */
.registry-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.registry-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 0;
  border-bottom: 1px solid var(--border);
}

.registry-item:last-child {
  border-bottom: none;
}
.registry-item-name {
  font-size: 14px;
  font-weight: 500;
}
.registry-item a {
  color: var(--accent);
  text-decoration: none;
  font-size: 13px;
}
.registry-item a:hover {
  text-decoration: underline;
}

/* Tags (capabilities / certs) */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.tag {
  background: rgba(59, 130, 246, 0.1);
  color: var(--accent);
  padding: 6px 12px;
  border-radius: 6px;
  font-size: 13px;
  font-weight: 500;
}

.tag.cert {
  background: rgba(245, 158, 11, 0.1);
  color: var(--orange);
}

.ecosystem-section {
  margin-bottom: 16px;
}
.ecosystem-section:last-child {
  margin-bottom: 0;
}

.ecosystem-label {
  font-size: 13px;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 8px;
}

/* Info List (sidebar) */
.info-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.info-item {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
}

.info-item:last-child {
  border-bottom: none;
}
.info-label {
  color: var(--text-muted);
  font-size: 13px;
}
.info-value {
  font-size: 14px;
  font-weight: 500;
}
.info-value a {
  color: var(--accent);
  text-decoration: none;
}
.info-value a:hover {
  text-decoration: underline;
}

/* Responsive */
@media (max-width: 768px) {
  .profile-grid {
    grid-template-columns: 1fr;
  }
  .state-header {
    flex-direction: column;
  }
  .state-info h1 {
    font-size: 22px;
  }
  .stat-badges {
    gap: 6px;
  }
  .quick-links {
    flex-direction: column;
  }
  .quick-links .btn {
    text-align: center;
    justify-content: center;
  }
}
