body {
  font-family: var(--font);
  color: var(--text);
  background:
    radial-gradient(circle at 18% 12%, rgba(124, 58, 237, 0.22), transparent 32%),
    radial-gradient(circle at 82% 8%, rgba(56, 189, 248, 0.16), transparent 28%),
    linear-gradient(180deg, #02040d 0%, #050816 48%, #02040d 100%);
  line-height: 1.6;
  overflow-x: hidden;
}

body.nav-open {
  overflow: hidden;
}

.shell {
  width: min(var(--shell), calc(100% - 32px));
  margin: 0 auto;
}

.section {
  position: relative;
  padding: 92px 0;
}

.glass {
  border: 1px solid var(--border);
  background:
    linear-gradient(145deg, rgba(15, 23, 42, 0.76), rgba(15, 23, 42, 0.42)),
    rgba(2, 6, 23, 0.34);
  box-shadow: var(--shadow-soft);
  backdrop-filter: blur(18px);
}

.cursor-glow {
  position: fixed;
  left: 0;
  top: 0;
  z-index: -1;
  width: 360px;
  height: 360px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(56, 189, 248, 0.13), transparent 66%);
  transform: translate(-50%, -50%);
  pointer-events: none;
}

.page-glow {
  position: fixed;
  z-index: -2;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(24px);
  opacity: 0.42;
  pointer-events: none;
}

.page-glow-one {
  left: -120px;
  top: 140px;
  background: radial-gradient(circle, rgba(124, 58, 237, 0.34), transparent 68%);
}

.page-glow-two {
  right: -160px;
  top: 45%;
  background: radial-gradient(circle, rgba(37, 99, 235, 0.3), transparent 68%);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  border-bottom: 1px solid transparent;
  transition: background 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.site-header.scrolled {
  border-color: var(--border);
  background: rgba(2, 4, 13, 0.78);
  box-shadow: 0 16px 42px rgba(0, 0, 0, 0.28);
  backdrop-filter: blur(18px);
}

.nav {
  min-height: var(--nav-height);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}

.brand {
  display: inline-flex;
  align-items: center;
}

.brand-mark {
  width: 44px;
  height: 44px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(168, 85, 247, 0.46);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(37, 99, 235, 0.34), rgba(168, 85, 247, 0.28));
  box-shadow: 0 18px 54px rgba(124, 58, 237, 0.28);
  font-weight: 900;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 6px;
}

.nav-links a {
  padding: 10px 12px;
  border-radius: var(--radius);
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 700;
  transition: color 180ms ease, background 180ms ease;
}

.nav-links a:hover {
  color: var(--text);
  background: rgba(148, 163, 184, 0.1);
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.nav-toggle span {
  display: block;
  width: 18px;
  height: 2px;
  margin: 5px auto;
  border-radius: 999px;
  background: var(--text);
}

/* Hero */
.hero {
  min-height: calc(100vh - var(--nav-height));
  display: grid;
  align-items: center;
  padding-top: 72px;
  overflow: hidden;
}

.hero-orbit {
  position: absolute;
  inset: 12% 8% auto auto;
  width: 440px;
  height: 440px;
  border: 1px solid rgba(96, 165, 250, 0.16);
  border-radius: 50%;
  background:
    radial-gradient(circle, rgba(56, 189, 248, 0.14), transparent 58%),
    conic-gradient(from 140deg, rgba(168, 85, 247, 0.34), transparent, rgba(56, 189, 248, 0.25), transparent);
  filter: blur(0.2px);
  opacity: 0.8;
  transform: translateY(var(--parallax-offset, 0));
}

.hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 44px;
}

.hero-copy {
  max-width: 850px;
}

.eyebrow {
  margin-bottom: 14px;
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1,
h2,
h3 {
  line-height: 1.05;
  letter-spacing: 0;
}

h1 {
  max-width: 900px;
  margin-bottom: 16px;
  font-size: 4.2rem;
}

h2 {
  max-width: 820px;
  margin-bottom: 18px;
  font-size: 2.35rem;
}

h3 {
  font-size: 1.18rem;
}

.hero-subtitle {
  min-height: 42px;
  margin-bottom: 18px;
  color: var(--muted-strong);
  font-size: 1.55rem;
  font-weight: 800;
}

.typed-text {
  background: linear-gradient(90deg, var(--blue), var(--purple));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-description,
.section-copy p,
.project-card p,
.timeline-card p,
.contact-copy p {
  color: var(--muted);
}

.hero-description {
  max-width: 700px;
  margin-bottom: 30px;
  font-size: 1.08rem;
}

.hero-actions,
.project-actions,
.badge-list,
.profile-meta,
.deployment-badge,
.hosting-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.deployment-badge {
  width: fit-content;
  margin-bottom: 28px;
  padding: 8px;
  border: 1px solid rgba(96, 165, 250, 0.24);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.62);
  box-shadow: 0 16px 42px rgba(37, 99, 235, 0.18);
  backdrop-filter: blur(16px);
}

.deployment-badge span {
  padding: 5px 8px;
  color: var(--muted-strong);
  font-size: 0.78rem;
  font-weight: 900;
}

.button,
.small-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  font-weight: 900;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.button {
  padding: 12px 18px;
}

.small-button {
  min-height: 40px;
  padding: 9px 13px;
  font-size: 0.9rem;
}

.button:hover,
.small-button:hover {
  transform: translateY(-2px);
}

.button-primary,
.small-button {
  background: linear-gradient(135deg, var(--blue-deep), var(--purple-deep));
  box-shadow: 0 18px 48px rgba(37, 99, 235, 0.3);
}

.button-secondary,
.button-ghost,
.small-button.muted {
  border-color: rgba(148, 163, 184, 0.24);
  background: rgba(15, 23, 42, 0.66);
  box-shadow: none;
}

.button-ghost {
  color: var(--muted-strong);
}

.hero-visual {
  display: grid;
  gap: 18px;
}

.terminal-card,
.stack-card,
.profile-card,
.skill-category,
.project-card,
.status-card,
.timeline-card,
.contact-panel {
  border-radius: var(--radius);
}

.terminal-card {
  padding: 24px;
}

.terminal-top {
  display: flex;
  gap: 8px;
  margin-bottom: 22px;
}

.terminal-top span,
.online-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
}

.terminal-top span:nth-child(1) {
  background: var(--danger);
}

.terminal-top span:nth-child(2) {
  background: var(--warning);
}

.terminal-top span:nth-child(3),
.online-dot {
  background: var(--green);
}

.terminal-lines {
  min-height: 170px;
}

.terminal-lines p {
  margin-bottom: 12px;
  color: #dbeafe;
  font-family: var(--mono);
  font-size: 0.95rem;
}

.terminal-success {
  color: var(--green) !important;
}

.prompt {
  color: var(--purple);
}

.stack-card {
  padding: 22px;
}

.stack-label {
  display: block;
  margin-bottom: 12px;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.stack-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  padding: 12px 0;
  border-top: 1px solid rgba(148, 163, 184, 0.12);
}

.stack-row strong {
  color: var(--green);
}

/* Profile */
.about-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 28px;
}

.profile-card {
  overflow: hidden;
}

.profile-image {
  aspect-ratio: 16 / 10;
  overflow: hidden;
}

.profile-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.profile-meta {
  padding: 18px;
}

.profile-meta span,
.badge-list span {
  border: 1px solid rgba(148, 163, 184, 0.15);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: #dbeafe;
  font-size: 0.8rem;
  font-weight: 800;
}

.profile-meta span {
  padding: 7px 10px;
}

.section-heading {
  margin-bottom: 34px;
}

.section-copy p + p {
  margin-top: 16px;
}

/* Skills and projects */
.skill-categories,
.dashboard-grid,
.contact-links {
  display: grid;
  gap: 18px;
}

.projects-grid {
  display: grid;
  grid-template-columns: 1fr;
  justify-content: center;
  align-items: stretch;
  gap: 24px;
}

.skill-category {
  padding: 22px;
}

.category-header {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 18px;
}

.category-icon,
.skill-pill i {
  display: grid;
  place-items: center;
  border: 1px solid rgba(96, 165, 250, 0.28);
  background: rgba(56, 189, 248, 0.1);
  color: var(--blue);
  font-style: normal;
  font-weight: 900;
}

.category-icon {
  width: 38px;
  height: 38px;
  border-radius: var(--radius);
}

.skills-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
}

.skill-pill {
  min-height: 58px;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  background: var(--surface-soft);
  color: var(--muted-strong);
  font-weight: 800;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease;
}

.skill-pill:hover {
  transform: translateY(-3px);
  border-color: var(--border-bright);
  background: rgba(37, 99, 235, 0.13);
}

.skill-pill i {
  flex: 0 0 auto;
  width: 34px;
  height: 34px;
  border-radius: 7px;
  font-size: 0.68rem;
}

.project-card {
  position: relative;
  display: grid;
  grid-template-rows: minmax(440px, 46%) 1fr;
  height: 100%;
  min-height: 100%;
  overflow: hidden;
  --project-accent: var(--blue);
  --project-accent-rgb: 56, 189, 248;
  transition: transform 220ms ease, border-color 220ms ease, box-shadow 220ms ease;
}

.project-card::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 0%, rgba(var(--project-accent-rgb), 0.2), transparent 46%);
  opacity: 0;
  transition: opacity 180ms ease;
  pointer-events: none;
}

.project-card:hover {
  transform: translateY(-7px);
  border-color: rgba(var(--project-accent-rgb), 0.62);
  box-shadow: 0 34px 98px rgba(var(--project-accent-rgb), 0.24), var(--shadow-soft);
}

.project-card:hover::before {
  opacity: 1;
}

.project-visual {
  position: relative;
  min-height: 440px;
  display: grid;
  grid-template-rows: auto 1fr;
  gap: 16px;
  padding: 24px 24px 74px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.14);
  background:
    radial-gradient(circle at 18% 12%, rgba(var(--project-accent-rgb), 0.26), transparent 34%),
    radial-gradient(circle at 88% 16%, rgba(168, 85, 247, 0.16), transparent 36%),
    linear-gradient(135deg, rgba(var(--project-accent-rgb), 0.15), rgba(2, 6, 23, 0.78)),
    repeating-linear-gradient(135deg, rgba(255,255,255,0.04) 0 1px, transparent 1px 14px);
}

.project-blue {
  --project-accent: var(--blue);
  --project-accent-rgb: 56, 189, 248;
}

.project-purple {
  --project-accent: var(--purple);
  --project-accent-rgb: 168, 85, 247;
}

.project-green {
  --project-accent: var(--green);
  --project-accent-rgb: 52, 211, 153;
}

.project-icon {
  width: 54px;
  height: 54px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(var(--project-accent-rgb), 0.38);
  border-radius: var(--radius);
  background: linear-gradient(135deg, rgba(var(--project-accent-rgb), 0.34), rgba(168, 85, 247, 0.2));
  color: var(--text);
  box-shadow: 0 18px 54px rgba(var(--project-accent-rgb), 0.22);
  font-weight: 900;
}

.vertical-flow {
  align-self: center;
  margin: auto 0;
  display: grid;
  justify-items: center;
  gap: 9px;
  transition: transform 220ms ease;
}

.vertical-flow span,
.project-status {
  border: 1px solid rgba(var(--project-accent-rgb), 0.22);
  border-radius: var(--radius);
  background: rgba(2, 6, 23, 0.62);
  color: #e7f0ff;
  font-size: 0.78rem;
  font-weight: 900;
}

.vertical-flow span {
  width: min(100%, 210px);
  max-width: 100%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 7px 11px;
  text-align: center;
  overflow-wrap: anywhere;
}

.vertical-flow span svg {
  flex: 0 0 auto;
  width: 15px;
  height: 15px;
  fill: none;
  stroke: var(--project-accent);
  stroke-width: 1.8;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.vertical-flow i {
  position: relative;
  width: 2px;
  height: 20px;
  border-radius: 999px;
  background: rgba(var(--project-accent-rgb), 0.2);
  overflow: hidden;
}

.vertical-flow i::before {
  content: "";
  position: absolute;
  inset: -100% 0 auto;
  height: 100%;
  background: linear-gradient(180deg, transparent, var(--project-accent), transparent);
  animation: flow-arrow 1.7s linear infinite;
}

.vertical-flow i::after {
  content: "";
  position: absolute;
  left: 50%;
  bottom: 0;
  width: 7px;
  height: 7px;
  border-right: 2px solid var(--project-accent);
  border-bottom: 2px solid var(--project-accent);
  transform: translateX(-50%) rotate(45deg);
}

.project-card:hover .vertical-flow {
  transform: scale(1.035);
}

.project-status {
  position: absolute;
  left: 22px;
  bottom: 22px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 11px;
  z-index: 2;
}

.project-status .online-dot {
  margin: 0;
}

.project-card:hover .project-icon {
  border-color: rgba(var(--project-accent-rgb), 0.58);
  box-shadow: 0 0 42px rgba(var(--project-accent-rgb), 0.3);
}

.project-body {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 26px 22px 22px;
}

.project-body h3 + .project-detail {
  margin-top: 2px;
}

.project-body h3 {
  display: flex;
  align-items: center;
  gap: 10px;
}

.project-body h3 svg {
  flex: 0 0 auto;
  width: 24px;
  height: 24px;
  stroke: var(--project-accent);
  stroke-width: 1.8;
  fill: none;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.project-detail {
  display: grid;
  gap: 4px;
}

.project-detail strong {
  color: var(--muted-strong);
  font-size: 0.84rem;
}

.project-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.project-metrics span {
  padding: 6px 9px;
  border: 1px solid rgba(var(--project-accent-rgb), 0.18);
  border-radius: 999px;
  background: rgba(var(--project-accent-rgb), 0.08);
  color: var(--muted-strong);
  font-size: 0.76rem;
  font-weight: 900;
}

.badge-list span {
  padding: 5px 8px;
  font-size: 0.74rem;
  border-color: rgba(var(--project-accent-rgb), 0.16);
}

.small-button.disabled,
.small-button[aria-disabled="true"] {
  cursor: not-allowed;
  opacity: 0.56;
  pointer-events: none;
  box-shadow: none;
  transform: none;
}

.small-button.disabled:hover,
.small-button[aria-disabled="true"]:hover {
  transform: none;
  border-color: rgba(148, 163, 184, 0.24);
  box-shadow: none;
}

.project-actions {
  margin-top: auto;
}

.section-lead {
  max-width: 720px;
  color: var(--muted);
  font-size: 1.04rem;
}

/* Hosting architecture */
.hosting-flow {
  display: grid;
  gap: 12px;
  max-width: 760px;
  margin: 0 auto 22px;
  padding: 22px;
  border-radius: var(--radius);
}

.flow-card {
  min-height: 62px;
  display: grid;
  place-items: center;
  padding: 14px;
  border: 1px solid rgba(96, 165, 250, 0.22);
  border-radius: var(--radius);
  background:
    linear-gradient(135deg, rgba(37, 99, 235, 0.16), rgba(168, 85, 247, 0.12)),
    rgba(2, 6, 23, 0.46);
  color: var(--muted-strong);
  font-weight: 900;
  text-align: center;
}

.domain-card {
  border-color: rgba(52, 211, 153, 0.34);
  color: var(--green);
}

.flow-arrow {
  display: grid;
  place-items: center;
  color: var(--blue);
  font-size: 1.3rem;
  font-weight: 900;
  line-height: 1;
}

.hosting-badges {
  justify-content: center;
}

.hosting-badges span {
  padding: 8px 11px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.66);
  color: #dbeafe;
  font-size: 0.84rem;
  font-weight: 900;
}

.cv-section {
  padding-top: 28px;
}

.cv-panel {
  display: grid;
  gap: 24px;
  align-items: center;
  padding: 28px;
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 86% 18%, rgba(168, 85, 247, 0.24), transparent 36%),
    linear-gradient(145deg, rgba(15, 23, 42, 0.86), rgba(15, 23, 42, 0.48));
}

.cv-panel p {
  color: var(--muted);
}

.cv-button {
  min-height: 58px;
  box-shadow: 0 24px 70px rgba(124, 58, 237, 0.36);
}

/* API-ready status cards */
.dashboard-header {
  display: grid;
  gap: 18px;
  margin-bottom: 28px;
}

.api-note {
  justify-self: start;
  align-self: start;
  padding: 8px 11px;
  border: 1px solid rgba(52, 211, 153, 0.24);
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.08);
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 900;
}

.status-card {
  position: relative;
  min-height: 174px;
  padding: 22px;
  transition: transform 180ms ease, border-color 180ms ease;
}

.status-card:hover {
  transform: translateY(-5px);
  border-color: rgba(52, 211, 153, 0.34);
}

.online-dot {
  position: relative;
  display: block;
  margin-bottom: 28px;
  box-shadow: 0 0 22px rgba(52, 211, 153, 0.88);
}

.status-card p {
  margin: 8px 0 18px;
  color: var(--muted);
}

.status-card strong {
  color: var(--green);
}

.timeline {
  position: relative;
  display: grid;
  gap: 22px;
}

.timeline::before {
  content: "";
  position: absolute;
  left: 36px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: linear-gradient(var(--blue), var(--purple));
}

.timeline-item {
  position: relative;
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  gap: 18px;
  align-items: start;
}

.timeline-year {
  position: relative;
  z-index: 1;
  display: grid;
  place-items: center;
  width: 74px;
  height: 44px;
  border: 1px solid rgba(96, 165, 250, 0.3);
  border-radius: var(--radius);
  background: var(--bg);
  color: var(--blue);
  font-weight: 900;
}

.timeline-card {
  padding: 20px;
}

.timeline-card h3 {
  margin-bottom: 8px;
}

.contact-panel {
  display: grid;
  gap: 28px;
  padding: 24px;
}

.contact-copy {
  max-width: 620px;
}

.contact-link {
  display: grid;
  gap: 6px;
  min-height: 88px;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  background: rgba(2, 6, 23, 0.36);
  transition: transform 180ms ease, border-color 180ms ease;
}

.contact-link:hover {
  transform: translateY(-4px);
  border-color: var(--border-bright);
}

.contact-link span {
  color: var(--blue);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.contact-link strong {
  overflow-wrap: anywhere;
}

.footer {
  border-top: 1px solid var(--border);
  background: rgba(2, 6, 23, 0.55);
  color: var(--muted);
}

.footer-grid {
  display: grid;
  gap: 8px;
  padding: 28px 0;
}

.footer-status {
  color: var(--muted-strong);
  font-weight: 900;
}

/* Homelab detail page */
.project-page .site-header {
  background: rgba(2, 4, 13, 0.58);
  backdrop-filter: blur(18px);
}

.project-nav-links {
  display: none;
}

.project-hero {
  min-height: calc(88vh - var(--nav-height));
  display: grid;
  align-items: center;
  overflow: hidden;
}

.project-hero-grid,
.detail-split {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 32px;
}

.project-hero-copy {
  max-width: 820px;
}

.detail-copy {
  padding: 24px;
  border-radius: var(--radius);
}

.detail-copy p {
  color: var(--muted);
  font-size: 1.05rem;
}

.service-grid,
.learning-grid,
.future-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 250px), 1fr));
  gap: 18px;
}

.service-card {
  min-height: 220px;
  display: grid;
  align-content: start;
  gap: 10px;
  padding: 22px;
  border-radius: var(--radius);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.service-card:hover,
.mini-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-soft);
}

.service-card p {
  color: var(--muted);
}

.service-card strong {
  color: var(--green);
}

.service-badge {
  justify-self: start;
  margin-top: 8px;
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.72);
  color: #dbeafe;
  font-size: 0.8rem;
  font-weight: 900;
}

.mini-card {
  min-height: 96px;
  display: grid;
  place-items: center;
  padding: 18px;
  border-radius: var(--radius);
  color: var(--muted-strong);
  font-weight: 900;
  text-align: center;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

/* Lab infrastructure page */
.lab-status-badge {
  border-color: rgba(52, 211, 153, 0.24);
  background: rgba(52, 211, 153, 0.08);
}

.metric-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 180px), 1fr));
  gap: 18px;
}

.metric-card {
  min-height: 158px;
  display: grid;
  align-content: space-between;
  gap: 18px;
  padding: 20px;
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 86% 12%, rgba(96, 165, 250, 0.18), transparent 34%),
    rgba(2, 6, 23, 0.46);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.metric-card:hover {
  transform: translateY(-5px);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-soft);
}

.metric-card span {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0;
  text-transform: uppercase;
}

.metric-card strong {
  color: #eff6ff;
  font-size: clamp(1.45rem, 4vw, 2.1rem);
  font-weight: 950;
}

.metric-card.metric-card-offline {
  opacity: 0.68;
  border-color: rgba(251, 113, 133, 0.42);
  background:
    radial-gradient(circle at 86% 12%, rgba(251, 113, 133, 0.2), transparent 34%),
    rgba(69, 10, 10, 0.46);
}

.metric-card.metric-card-offline strong {
  color: var(--danger);
}

.metric-card.metric-card-offline .metric-state {
  border-color: rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
  color: var(--danger);
}

.metric-card.metric-card-offline .metric-bar i {
  background: linear-gradient(90deg, var(--danger), rgba(251, 113, 133, 0.52));
  box-shadow: 0 0 18px rgba(251, 113, 133, 0.34);
}

.metric-updated {
  justify-self: start;
  margin-top: 12px;
  padding: 7px 10px;
  border: 1px solid rgba(96, 165, 250, 0.18);
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.58);
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 900;
}

.metric-updated.metric-updated-error {
  border-color: rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
  color: var(--danger);
}

.metric-bar {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.12);
}

.metric-bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--purple));
  box-shadow: 0 0 22px rgba(96, 165, 250, 0.34);
}

.metric-state {
  justify-self: start;
  padding: 7px 10px;
  border: 1px solid rgba(52, 211, 153, 0.22);
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.08);
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 900;
}

.table-wrap {
  overflow-x: auto;
  border-radius: var(--radius);
}

.services-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.services-table th,
.services-table td {
  padding: 18px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  text-align: left;
}

.services-table th {
  color: var(--blue);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.services-table td {
  color: var(--muted-strong);
}

.services-table tr:last-child td {
  border-bottom: 0;
}

.status-pill {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid rgba(52, 211, 153, 0.22);
  border-radius: 999px;
  background: rgba(52, 211, 153, 0.08);
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 900;
}

.status-pill::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: var(--green);
  box-shadow: 0 0 14px rgba(52, 211, 153, 0.76);
}

.workflow-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  padding: 22px;
  border-radius: var(--radius);
}

.workflow-strip span {
  position: relative;
  flex: 1 1 150px;
  min-height: 58px;
  display: grid;
  place-items: center;
  padding: 12px;
  border: 1px solid rgba(96, 165, 250, 0.2);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.64);
  color: var(--muted-strong);
  font-weight: 900;
  text-align: center;
}

.workflow-strip span:not(:last-child)::after {
  content: ">";
  position: absolute;
  right: -12px;
  color: var(--blue);
  font-weight: 950;
}

.docker-dashboard {
  display: grid;
  gap: 24px;
  padding: 26px;
  border-radius: var(--radius);
}

.docker-header {
  display: grid;
  gap: 18px;
  align-items: start;
}

.docker-refresh {
  justify-self: start;
  min-width: 118px;
}

.docker-refresh:disabled {
  cursor: wait;
  opacity: 0.62;
}

.docker-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 190px), 1fr));
  gap: 14px;
}

.docker-summary-card {
  min-height: 126px;
  display: flex;
  gap: 14px;
  align-items: flex-start;
  padding: 18px;
  border: 1px solid rgba(148, 163, 184, 0.14);
  border-radius: var(--radius);
  background:
    radial-gradient(circle at 86% 12%, rgba(124, 58, 237, 0.18), transparent 34%),
    rgba(15, 23, 42, 0.54);
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.docker-summary-card > div {
  min-width: 0;
  display: grid;
  gap: 8px;
}

.docker-summary-card:hover {
  transform: translateY(-4px);
  border-color: var(--border-bright);
  box-shadow: var(--shadow-soft);
}

.docker-summary-card span {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.docker-summary-card strong {
  color: #eff6ff;
  font-size: clamp(1.35rem, 3vw, 1.8rem);
  font-weight: 950;
  overflow-wrap: anywhere;
}

.docker-summary-card small {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
}

.docker-stat-icon,
.docker-summary-icon {
  flex: 0 0 auto;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid rgba(96, 165, 250, 0.2);
  border-radius: 12px;
  background: rgba(15, 23, 42, 0.72);
  color: var(--blue);
}

.docker-stat-icon svg,
.docker-summary-icon svg {
  width: 26px;
  height: 26px;
  display: block;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.docker-stat-icon svg *,
.docker-summary-icon svg * {
  fill: none;
  stroke: currentColor;
}

.docker-summary-total .docker-summary-icon {
  color: var(--blue);
}

.docker-summary-running .docker-summary-icon,
.docker-summary-running strong {
  color: var(--green);
}

.docker-summary-stopped .docker-summary-icon,
.docker-summary-stopped strong {
  color: var(--danger);
}

.docker-summary-updated .docker-summary-icon {
  color: var(--purple);
}

.docker-message {
  padding: 16px;
  border: 1px solid rgba(96, 165, 250, 0.18);
  border-radius: var(--radius);
  background: rgba(15, 23, 42, 0.58);
  color: var(--muted-strong);
  font-weight: 800;
}

.docker-message-warning {
  border-color: rgba(251, 191, 36, 0.3);
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
}

.docker-message-error {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  border-color: rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
  color: var(--danger);
}

.docker-table-wrap {
  overflow-x: auto;
  border: 1px solid rgba(148, 163, 184, 0.12);
  border-radius: var(--radius);
  background: rgba(2, 6, 23, 0.3);
}

.docker-table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
}

.docker-table th,
.docker-table td {
  padding: 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.12);
  text-align: left;
  vertical-align: middle;
}

.docker-table th {
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 900;
  text-transform: uppercase;
}

.docker-table td {
  color: var(--muted-strong);
}

.docker-table tbody tr {
  transition: background 180ms ease, box-shadow 180ms ease;
}

.docker-table tbody tr:hover {
  background: rgba(96, 165, 250, 0.06);
  box-shadow: inset 3px 0 0 rgba(96, 165, 250, 0.58);
}

.docker-table tr:last-child td {
  border-bottom: 0;
}

.docker-service {
  display: inline-flex;
  gap: 10px;
  align-items: center;
  min-width: 0;
}

.docker-service svg {
  flex: 0 0 auto;
  width: 18px;
  height: 18px;
  fill: none;
  stroke: var(--blue);
  stroke-width: 2;
}

.docker-service strong {
  color: #eff6ff;
  overflow-wrap: anywhere;
}

.docker-image {
  display: grid;
  gap: 4px;
}

.docker-image code {
  color: #dbeafe;
  white-space: normal;
  overflow-wrap: anywhere;
}

.docker-image small {
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 800;
}

.docker-uptime {
  overflow-wrap: anywhere;
}

.docker-ports {
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
  max-width: 340px;
}

.docker-port-badge,
.docker-no-ports {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 6px 9px;
  border: 1px solid rgba(96, 165, 250, 0.18);
  border-radius: 999px;
  background: rgba(96, 165, 250, 0.08);
  color: #dbeafe;
  font-size: 0.78rem;
  font-weight: 900;
  white-space: normal;
}

.docker-no-ports {
  border-color: rgba(148, 163, 184, 0.14);
  background: rgba(148, 163, 184, 0.08);
  color: var(--muted);
}

.docker-state {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 7px 10px;
  border: 1px solid rgba(148, 163, 184, 0.16);
  border-radius: 999px;
  background: rgba(148, 163, 184, 0.08);
  color: var(--muted-strong);
  font-size: 0.78rem;
  font-weight: 900;
}

.docker-state::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 14px currentColor;
}

.docker-state-running {
  border-color: rgba(52, 211, 153, 0.24);
  background: rgba(52, 211, 153, 0.08);
  color: var(--green);
}

.docker-state-stopped {
  border-color: rgba(251, 113, 133, 0.28);
  background: rgba(251, 113, 133, 0.1);
  color: var(--danger);
}

.docker-state-other {
  border-color: rgba(251, 191, 36, 0.3);
  background: rgba(251, 191, 36, 0.1);
  color: #fbbf24;
}

@media (min-width: 760px) {
  .docker-header {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .docker-refresh {
    justify-self: end;
  }
}

@media (max-width: 760px) {
  .docker-dashboard {
    padding: 20px;
  }

  .docker-table-wrap {
    overflow-x: visible;
    border: 0;
    background: transparent;
  }

  .docker-table {
    min-width: 0;
  }

  .docker-table thead {
    display: none;
  }

  .docker-table,
  .docker-table tbody,
  .docker-table tr,
  .docker-table td {
    display: block;
    width: 100%;
  }

  .docker-table tbody {
    display: grid;
    gap: 16px;
  }

  .docker-table tr {
    padding: 18px;
    border: 1px solid rgba(148, 163, 184, 0.14);
    border-radius: var(--radius);
    background:
      radial-gradient(circle at 88% 10%, rgba(96, 165, 250, 0.18), transparent 34%),
      linear-gradient(145deg, rgba(15, 23, 42, 0.78), rgba(15, 23, 42, 0.44));
  }

  .docker-table td {
    display: grid;
    grid-template-columns: minmax(92px, 0.42fr) minmax(0, 1fr);
    gap: 12px;
    align-items: start;
    padding: 10px 0;
    border-bottom: 1px solid rgba(148, 163, 184, 0.1);
  }

  .docker-table td::before {
    content: attr(data-label);
    color: var(--blue);
    font-size: 0.72rem;
    font-weight: 900;
    text-transform: uppercase;
  }

  .docker-table td:last-child {
    border-bottom: 0;
  }

  .docker-ports {
    max-width: none;
  }
}
