:root {
  --bg: #020617;
  --bg-elevated: #020817;
  --bg-card: #020617;
  --bg-soft: #020617;
  --border-subtle: rgba(148, 163, 184, 0.35);
  --border-strong: rgba(148, 163, 184, 0.6);
  --accent: #38bdf8;
  --accent-soft: rgba(56, 189, 248, 0.08);
  --accent-strong: #0ea5e9;
  --text: #e5e7eb;
  --text-soft: #9ca3af;
  --text-softer: #6b7280;
  --danger: #ef4444;
  --success: #22c55e;
  --radius-lg: 20px;
  --radius-xl: 26px;
  --shadow-soft: 0 24px 80px rgba(15, 23, 42, 0.9);
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  padding: 0;
}

body {
  min-height: 100vh;
  font-family: system-ui, -apple-system, BlinkMacSystemFont, "Inter", sans-serif;
  background-color: #0d1117;
  color: var(--text);
  -webkit-font-smoothing: antialiased;
}

.bg-glow {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: radial-gradient(circle at 50% -20%, rgba(56, 189, 248, 0.08), transparent 70%);
  pointer-events: none;
  z-index: -1;
  animation: pulseGlow 8s ease-in-out infinite alternate;
}

@keyframes pulseGlow {
  0% { opacity: 0.5; transform: scale(1); }
  100% { opacity: 1; transform: scale(1.1); }
}

@keyframes fadeInUp {
  from {
    opacity: 0;
    transform: translateY(15px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.animate-in {
  animation: fadeInUp 0.7s cubic-bezier(0.2, 0.8, 0.2, 1) both;
}

.site-header.animate-in { animation-delay: 0.1s; }
#about.animate-in { animation-delay: 0.2s; }
#projects.animate-in { animation-delay: 0.3s; }
#stack.animate-in { animation-delay: 0.4s; }
#contacts.animate-in { animation-delay: 0.5s; }

.page {
  min-height: 100vh;
}

.shell {
  width: 100%;
  max-width: none;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  background-color: #020617;
  border-radius: 0;
  border: 1px solid rgba(31, 41, 55, 0.9);
  box-shadow: none;
  padding: 20px 16px 14px;
  backdrop-filter: blur(22px);
}

@media (min-width: 768px) {
  .shell {
    padding: 22px 32px 16px;
  }
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-bottom: 16px;
  border-bottom: 1px solid rgba(148, 163, 184, 0.32);
}

.identity {
  display: flex;
  align-items: center;
  gap: 14px;
}

.avatar {
  width: 56px;
  height: 56px;
  border-radius: 999px;
  background: #111827;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.avatar-img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.avatar::after {
  content: none;
}

.identity-text {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.nickname {
  font-size: 20px;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.status-line {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.status-pill {
  padding: 4px 10px;
  border-radius: 999px;
  background: rgba(15, 23, 42, 0.8);
  border: 1px solid rgba(148, 163, 184, 0.45);
  color: var(--text-soft);
  font-size: 11px;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.status-block {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 2px;
  font-size: 12px;
}

.status-indicator {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-soft);
}

.status-indicator .dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background-color: #22c55e;
}

.status-time {
  font-family: "JetBrains Mono", ui-monospace, Menlo, Monaco, Consolas, "Liberation Mono",
    "Courier New", monospace;
  color: var(--text);
}

.section {
  padding-top: 20px;
  margin-top: 16px;
  border-top: 1px solid rgba(31, 41, 55, 0.9);
}

.section:last-of-type {
  border-bottom: none;
}

.section-title {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-soft);
}

.section-body {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.two-cols {
  display: grid;
  grid-template-columns: minmax(0, 1.1fr) minmax(0, 2fr);
  gap: 16px;
}

@media (max-width: 700px) {
  .two-cols {
    grid-template-columns: minmax(0, 1fr);
  }
}

.section-text {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

.section-text.subtle {
  color: var(--text-softer);
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  flex-shrink: 0;
}

.chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid rgba(75, 85, 99, 0.9);
  background-color: transparent;
  font-size: 11px;
  color: var(--text);
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

@media (max-width: 860px) {
  .projects-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.project-card {
  border-radius: 16px;
  border: 1px solid rgba(31, 41, 55, 0.9);
  background-color: #020617;
  padding: 12px 12px 10px;
}

.project-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 6px;
}

.project-title {
  margin: 0;
  font-size: 15px;
}

.project-title a {
  color: var(--text);
  text-decoration: none;
}

.project-title a:hover {
  color: var(--accent-strong);
}

.project-tag {
  font-size: 11px;
  color: var(--text-soft);
  border-radius: 999px;
  border: 1px solid rgba(148, 163, 184, 0.5);
  padding: 3px 8px;
}

.project-text {
  margin: 0;
  font-size: 13px;
  line-height: 1.6;
}

.project-text + .project-text {
  margin-top: 4px;
}

.project-text.subtle {
  color: var(--text-softer);
}

.project-actions {
  margin-top: 8px;
}

.project-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background-color: transparent;
  color: var(--text);
  font-size: 12px;
  text-decoration: none;
}

.project-button:hover {
  border-color: var(--accent-strong);
  background-color: rgba(15, 23, 42, 0.9);
}

.project-actions {
  margin-top: 8px;
}

.project-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 12px;
  border-radius: 999px;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background-color: transparent;
  color: var(--text);
  font-size: 12px;
  text-decoration: none;
}

.project-button:hover {
  border-color: var(--accent-strong);
  background-color: rgba(15, 23, 42, 0.9);
}

.hardware-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

@media (max-width: 860px) {
  .hardware-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.hardware-item {
  border-radius: 14px;
  border: 1px solid rgba(31, 41, 55, 0.9);
  background-color: #020617;
  padding: 8px 10px 8px;
}

.hardware-item summary {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 8px;
  list-style: none;
  cursor: pointer;
}

.hardware-item summary::-webkit-details-marker {
  display: none;
}

.hardware-item[open] {
  border-color: rgba(56, 189, 248, 0.7);
}

.hw-title {
  font-size: 13px;
  font-weight: 600;
}

.hw-meta {
  font-size: 11px;
  color: var(--text-soft);
}

.hw-body {
  margin-top: 6px;
}

.hw-body ul {
  margin: 0;
  padding-left: 17px;
  font-size: 12px;
  color: var(--text-softer);
  line-height: 1.5;
}

.dot {
  width: 9px;
  height: 9px;
  border-radius: 999px;
}

.site-footer {
  padding-top: 14px;
  margin-top: auto;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.footer-main {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  border-top: 1px solid rgba(148, 163, 184, 0.32);
  padding-top: 10px;
}

.footer-left {
  max-width: 60%;
}

.footer-title {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--text-soft);
  margin-bottom: 4px;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.social-links a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  padding: 0;
  border-radius: 999px;
  border: 1px solid rgba(55, 65, 81, 0.9);
  background-color: transparent;
  color: var(--text);
  text-decoration: none;
  transition: background-color 0.14s ease, border-color 0.14s ease, color 0.14s ease;
}

.social-links a:hover {
  border-color: var(--accent-strong);
  background-color: rgba(15, 23, 42, 0.9);
}

.icon {
  display: block;
}

.about-content {
  display: flex;
  align-items: center;
  gap: 16px;
}

@media (max-width: 700px) {
  .about-content {
    flex-direction: column;
    align-items: flex-start;
  }
}

.icon--social {
  width: 16px;
  height: 16px;
  object-fit: contain;
}

.icon--external {
  width: 11px;
  height: 11px;
}

.icon--chip {
  width: 16px;
  height: 16px;
}

.icon:not(.avatar-img) {
  filter: invert(1);
}

.footer-bottom {
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px dashed rgba(148, 163, 184, 0.32);
  padding-top: 8px;
  font-size: 11px;
  color: var(--text-softer);
}

@media (max-width: 700px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-main {
    flex-direction: column;
  }

  .footer-left {
    max-width: 100%;
  }
}

a {
  color: var(--accent);
}

a:hover {
  color: var(--accent-strong);
}
