:root {
  --bg: #0b1020;
  --bg-soft: #11172e;
  --surface: #ffffff;
  --surface-muted: #f6f7fb;
  --border: #e7e9f0;
  --text: #0f172a;
  --text-muted: #5b6478;
  --text-on-dark: #e6e8f2;
  --text-on-dark-muted: #aab2c5;
  --accent: #7c5cff;
  --accent-2: #22d3ee;
  --accent-grad: linear-gradient(135deg, #7c5cff 0%, #22d3ee 100%);
  --shadow-sm: 0 1px 2px rgba(15, 23, 42, 0.06);
  --shadow-md: 0 10px 30px -12px rgba(15, 23, 42, 0.18);
  --shadow-lg: 0 20px 50px -20px rgba(15, 23, 42, 0.35);
  --radius: 14px;
}

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

@media (min-width: 768px) {
  html { font-size: 16px; }
}

body {
  font-family: 'Inter', system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  color: var(--text);
  background: var(--surface-muted);
  margin: 0;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, h4,
.display-1, .display-2, .display-3, .display-4 {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  letter-spacing: -0.02em;
  font-weight: 700;
}

a { color: var(--accent); text-decoration: none; }
a:hover { color: #5a3df0; }

.btn:focus, .btn:active:focus, .btn-link.nav-link:focus,
.form-control:focus, .form-check-input:focus {
  box-shadow: 0 0 0 0.2rem rgba(124, 92, 255, 0.25);
}

/* ========== Navigation ========== */
.site-nav {
  background: rgba(255, 255, 255, 0.75);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid rgba(15, 23, 42, 0.06);
  padding: 0.65rem 0;
}

.site-nav .nav-link {
  color: var(--text) !important;
  font-weight: 500;
  padding: 0.4rem 0.9rem !important;
  border-radius: 8px;
  transition: color 0.15s, background 0.15s;
}

.site-nav .nav-link:hover {
  color: var(--accent) !important;
  background: rgba(124, 92, 255, 0.08);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 700;
  color: var(--text) !important;
}

.brand-mark {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  background: var(--accent-grad);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.85rem;
  letter-spacing: 0.05em;
  box-shadow: var(--shadow-sm);
}

.btn-accent {
  background: var(--accent-grad);
  color: #fff !important;
  border: none;
  font-weight: 600;
  border-radius: 999px;
  padding: 0.5rem 1.1rem;
  box-shadow: 0 6px 16px -6px rgba(124, 92, 255, 0.6);
  transition: transform 0.15s, box-shadow 0.15s, filter 0.15s;
}

.btn-accent:hover {
  transform: translateY(-1px);
  filter: brightness(1.05);
  color: #fff;
  box-shadow: 0 10px 22px -8px rgba(124, 92, 255, 0.7);
}

.btn-ghost {
  background: transparent;
  color: var(--text-on-dark) !important;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 999px;
  font-weight: 600;
  padding: 0.55rem 1.2rem;
  transition: background 0.15s, border-color 0.15s;
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.5);
  color: #fff !important;
}

/* ========== Layout ========== */
.site-main {
  padding-top: 80px; /* offset for fixed nav */
  min-height: calc(100vh - 200px);
}

.section { padding: 4.5rem 0; }
.section-title { font-size: 2rem; margin-bottom: 0.5rem; }
.section-eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.18em;
  font-size: 0.75rem;
  color: var(--accent);
  font-weight: 600;
  margin-bottom: 0.5rem;
}

/* ========== Hero ========== */
.hero {
  position: relative;
  overflow: hidden;
  color: var(--text-on-dark);
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(124, 92, 255, 0.35), transparent 60%),
    radial-gradient(900px 500px at 90% 10%, rgba(34, 211, 238, 0.25), transparent 60%),
    linear-gradient(180deg, #0b1020 0%, #11172e 100%);
  padding: 7rem 0 6rem;
  text-align: center;
}

.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.04) 1px, transparent 1px);
  background-size: 36px 36px;
  -webkit-mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
          mask-image: radial-gradient(ellipse at center, #000 30%, transparent 75%);
  pointer-events: none;
}

.hero > * { position: relative; z-index: 1; }

.hero .eyebrow {
  display: inline-block;
  padding: 0.35rem 0.85rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  color: var(--text-on-dark-muted);
  font-size: 0.8rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  margin-bottom: 1.25rem;
}

.hero h1 {
  font-size: clamp(2.5rem, 6vw, 4.5rem);
  line-height: 1.05;
  margin-bottom: 1rem;
  color: #fff;
}

.gradient-text {
  background: var(--accent-grad);
  -webkit-background-clip: text;
          background-clip: text;
  color: transparent;
}

.hero .lead {
  color: var(--text-on-dark-muted);
  font-size: 1.15rem;
  max-width: 640px;
  margin: 0 auto 2rem;
}

/* ========== Skills ========== */
.skill-pill {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.6rem 1.1rem;
  text-align: center;
  font-weight: 500;
  font-size: 0.95rem;
  box-shadow: var(--shadow-sm);
  transition: transform 0.15s, border-color 0.15s, color 0.15s;
}

.skill-pill:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  color: var(--accent);
}

/* ========== Project cards ========== */
.project-card {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  position: relative;
  transition: transform 0.2s, box-shadow 0.2s;
}

.project-card:hover {
  transform: translateY(-6px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(124, 92, 255, 0.45);
}

.project-card .card-title {
  font-family: 'Space Grotesk', sans-serif;
  font-weight: 600;
  letter-spacing: -0.01em;
}

.project-card .card-text { color: var(--text-muted); }

/* ========== Contact ========== */
.contact-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  text-align: center;
  box-shadow: var(--shadow-md);
}

/* ========== About page ========== */
.about-section { padding: 2rem 0 4rem; }

.profile-image-container {
  text-align: center;
  position: relative;
}

.profile-image-container::before {
  content: "";
  position: absolute;
  inset: -10px;
  border-radius: 50%;
  background: var(--accent-grad);
  filter: blur(28px);
  opacity: 0.35;
  z-index: 0;
}

.profile-image {
  position: relative;
  z-index: 1;
  width: 260px;
  height: 260px;
  max-width: 100%;
  object-fit: cover;
  border: 6px solid #fff;
  box-shadow: var(--shadow-lg);
}

.feature-box {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  height: 100%;
  transition: transform 0.15s, box-shadow 0.15s, border-color 0.15s;
}

.feature-box:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  border-color: rgba(124, 92, 255, 0.4);
}

.feature-icon {
  font-size: 1.5rem;
  width: 46px;
  height: 46px;
  border-radius: 12px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: rgba(124, 92, 255, 0.12);
  color: var(--accent);
  margin-bottom: 0.85rem;
}

/* ========== Footer ========== */
.site-footer {
  margin-top: 4rem;
  padding: 1.75rem 0;
  background: #0b1020;
  color: var(--text-on-dark-muted);
  font-size: 0.9rem;
}

.site-footer a {
  color: var(--text-on-dark-muted);
  margin-left: 0.85rem;
  transition: color 0.15s;
}

.site-footer a:hover { color: #fff; }
.footer-links i { font-size: 1.05rem; }

/* ========== Form helpers ========== */
.form-floating > .form-control-plaintext::placeholder,
.form-floating > .form-control::placeholder {
  color: var(--bs-secondary-color);
  text-align: end;
}

.form-floating > .form-control-plaintext:focus::placeholder,
.form-floating > .form-control:focus::placeholder {
  text-align: start;
}
