/* Base */
:root {
  --bg: #0b1220;
  --bg-elev: #0f1b33;
  --text: #eaf0ff;
  --muted: #b7c3e6;
  --border: rgba(255, 255, 255, 0.12);
  --brand: #7c5cff;
  --brand-2: #2dd4bf;
  --shadow: 0 12px 30px rgba(0, 0, 0, 0.35);

  --radius: 16px;
  --radius-sm: 12px;

  --container: 1100px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
  color: var(--text);
  background: radial-gradient(1200px 600px at 20% 10%, rgba(124, 92, 255, 0.28), transparent 50%),
    radial-gradient(800px 500px at 80% 20%, rgba(45, 212, 191, 0.18), transparent 55%),
    linear-gradient(180deg, var(--bg), #070b14);
  line-height: 1.55;
}

a {
  color: inherit;
}

img {
  max-width: 100%;
  height: auto;
}

.container {
  width: min(var(--container), calc(100% - 2rem));
  margin: 0 auto;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: 1rem;
  transform: translateY(-200%);
  background: var(--bg-elev);
  border: 1px solid var(--border);
  color: var(--text);
  padding: 0.6rem 0.85rem;
  border-radius: 999px;
  z-index: 100;
}

.skip-link:focus {
  transform: translateY(0);
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(11, 18, 32, 0.72);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.9rem 0;
  gap: 1rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  text-decoration: none;
}

.brand-mark {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  font-weight: 700;
  letter-spacing: 0.5px;
  background: linear-gradient(135deg, rgba(124, 92, 255, 0.9), rgba(45, 212, 191, 0.7));
  box-shadow: var(--shadow);
}

.brand-text {
  font-weight: 600;
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.nav-link {
  text-decoration: none;
  color: var(--muted);
  padding: 0.55rem 0.75rem;
  border-radius: 999px;
  border: 1px solid transparent;
}

.nav-link:hover {
  color: var(--text);
  border-color: rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
}

.nav-link--cta {
  color: var(--text);
  border-color: rgba(124, 92, 255, 0.35);
  background: rgba(124, 92, 255, 0.12);
}

.nav-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.nav-toggle-bars {
  position: relative;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
  width: 18px;
  height: 2px;
  background: currentColor;
  border-radius: 2px;
}

.nav-toggle-bars::before {
  top: -6px;
}

.nav-toggle-bars::after {
  top: 6px;
}

/* Sections */
.site-main {
  padding-bottom: 3rem;
}

.section {
  padding: 4.25rem 0;
}

.section--alt {
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.03), transparent);
  border-top: 1px solid rgba(255, 255, 255, 0.06);
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.section-head {
  margin-bottom: 1.6rem;
}

.section-title {
  margin: 0;
  font-size: clamp(1.6rem, 1.2rem + 1.2vw, 2.1rem);
  letter-spacing: -0.02em;
}

.section-kicker {
  margin: 0.35rem 0 0;
  color: var(--muted);
}

/* Hero */
.hero {
  padding: 4.5rem 0 3.25rem;
}

.hero-grid {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  gap: 2rem;
  align-items: center;
}

.eyebrow {
  margin: 0;
  color: var(--muted);
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-size: 0.85rem;
}

.hero-title {
  margin: 0.25rem 0 0;
  font-size: clamp(2.4rem, 1.8rem + 2.6vw, 3.6rem);
  letter-spacing: -0.04em;
}

.hero-subtitle {
  margin: 0.9rem 0 0;
  color: var(--muted);
  max-width: 58ch;
}

.hero-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-top: 1.25rem;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.85rem 1.1rem;
  border-radius: 999px;
  border: 1px solid rgba(124, 92, 255, 0.45);
  background: rgba(124, 92, 255, 0.16);
  text-decoration: none;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
}

.button:hover {
  background: rgba(124, 92, 255, 0.22);
}

.button--ghost {
  border-color: rgba(255, 255, 255, 0.16);
  background: rgba(255, 255, 255, 0.06);
}

.button--ghost:hover {
  background: rgba(255, 255, 255, 0.09);
}

.hero-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1.5rem 0 0;
  padding: 0;
}

.meta-item {
  padding: 0.85rem 0.95rem;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
  border-radius: var(--radius-sm);
}

.meta-item dt {
  color: var(--muted);
  font-size: 0.85rem;
}

.meta-item dd {
  margin: 0.25rem 0 0;
  font-weight: 600;
}

.hero-card {
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.avatar {
  display: grid;
  place-items: center;
  height: 140px;
  background: linear-gradient(135deg, rgba(124, 92, 255, 0.55), rgba(45, 212, 191, 0.35));
}

.avatar span {
  display: inline-grid;
  place-items: center;
  width: 74px;
  height: 74px;
  border-radius: 999px;
  background: rgba(11, 18, 32, 0.55);
  border: 1px solid rgba(255, 255, 255, 0.14);
  font-weight: 800;
  letter-spacing: 0.08em;
}

.card-body {
  padding: 1.1rem 1.1rem 1.2rem;
}

.card-title {
  margin: 0;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.card-text {
  margin: 0.5rem 0 0;
  color: var(--muted);
}

.card-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.9rem;
}

.chip {
  text-decoration: none;
  font-weight: 600;
  font-size: 0.92rem;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
}

.chip:hover {
  background: rgba(255, 255, 255, 0.09);
}

/* About */
.two-col {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1.5rem;
}

.prose p {
  margin: 0.6rem 0;
  color: var(--muted);
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
}

.stat {
  padding: 1rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
}

.stat-number {
  margin: 0;
  font-size: 1.6rem;
  font-weight: 800;
  letter-spacing: -0.02em;
}

.stat-label {
  margin: 0.25rem 0 0;
  color: var(--muted);
}

/* Cards / Projects */
.cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.card {
  padding: 1.2rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
}

.card-h {
  margin: 0;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
}

.card-p {
  margin: 0.6rem 0 0;
  color: var(--muted);
}

.tags {
  list-style: none;
  padding: 0;
  margin: 0.9rem 0 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.tag {
  padding: 0.35rem 0.6rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  color: var(--text);
  background: rgba(255, 255, 255, 0.06);
  font-size: 0.9rem;
  font-weight: 600;
}

.card-cta {
  display: flex;
  gap: 0.9rem;
  margin-top: 1rem;
}

.link {
  color: var(--text);
  text-decoration: none;
  border-bottom: 1px solid rgba(255, 255, 255, 0.22);
  padding-bottom: 0.08rem;
}

.link:hover {
  border-bottom-color: rgba(124, 92, 255, 0.7);
}

/* Skills */
.skills {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1rem;
}

.skill {
  padding: 1.2rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
}

.skill-h {
  margin: 0;
  font-size: 1.05rem;
}

.skill-p {
  margin: 0.6rem 0 0;
  color: var(--muted);
}

/* Contact */
.contact-grid {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 1rem;
  align-items: start;
}

.form {
  padding: 1.2rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
}

.field {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}

.label {
  color: var(--muted);
  font-weight: 600;
  font-size: 0.92rem;
}

.input,
.textarea {
  width: 100%;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.14);
  background: rgba(11, 18, 32, 0.55);
  color: var(--text);
  padding: 0.75rem 0.85rem;
  font: inherit;
}

.input:focus,
.textarea:focus {
  outline: 2px solid rgba(124, 92, 255, 0.45);
  outline-offset: 2px;
}

.form-note {
  margin: 0.65rem 0 0;
  color: var(--muted);
  min-height: 1.2em;
}

.contact-aside {
  display: grid;
  gap: 0.75rem;
}

.contact-box {
  padding: 1.2rem;
  border-radius: var(--radius);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(15, 27, 51, 0.55);
}

.contact-h {
  margin: 0;
}

.contact-p {
  margin: 0.55rem 0 0;
  color: var(--muted);
}

.sep {
  margin: 0 0.35rem;
  color: rgba(255, 255, 255, 0.3);
}

/* Footer */
.site-footer {
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  padding: 1.25rem 0;
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.footer-text {
  margin: 0;
  color: var(--muted);
}

/* Responsive */
@media (max-width: 900px) {
  .hero-grid {
    grid-template-columns: 1fr;
  }

  .two-col {
    grid-template-columns: 1fr;
  }

  .cards {
    grid-template-columns: 1fr;
  }

  .skills {
    grid-template-columns: 1fr;
  }

  .contact-grid {
    grid-template-columns: 1fr;
  }

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

@media (max-width: 820px) {
  .nav-toggle {
    display: inline-flex;
  }

  .site-nav {
    position: absolute;
    right: 1rem;
    top: 64px;
    min-width: min(92vw, 320px);
    flex-direction: column;
    align-items: stretch;
    gap: 0.25rem;
    padding: 0.75rem;
    border-radius: var(--radius);
    border: 1px solid rgba(255, 255, 255, 0.14);
    background: rgba(11, 18, 32, 0.92);
    box-shadow: var(--shadow);
    display: none;
  }

  .site-nav.is-open {
    display: flex;
  }

  .nav-link {
    padding: 0.85rem 0.9rem;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }
}
