@font-face {
  font-family: "Inter";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("/assets/fonts/inter-latin-wght.woff2") format("woff2");
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #09090b;
  --bg-card: #111113;
  --bg-card-hover: #161618;
  --text: #fafafa;
  --text-muted: #71717a;
  --text-secondary: #a1a1aa;
  --accent: #6366f1;
  --accent-light: #818cf8;
  --accent-glow: rgba(99, 102, 241, 0.15);
  --border: #27272a;
  --border-hover: #3f3f46;
  --radius: 14px;
  --radius-sm: 8px;
}

html { scroll-behavior: smooth; }

body {
  font-family: "Inter", "Segoe UI", system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle, #27272a 1px, transparent 1px);
  background-size: 32px 32px;
  opacity: 0.35;
  pointer-events: none;
  z-index: 0;
}

* { position: relative; z-index: 1; }

/* ── Nav ── */
nav {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(9, 9, 11, 0.85);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border-bottom: 1px solid var(--border);
  padding: 0 clamp(1rem, 5vw, 3rem);
  height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

nav .logo {
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--text);
  text-decoration: none;
  letter-spacing: -0.01em;
}

nav .logo span { color: var(--accent-light); }

nav ul { list-style: none; display: flex; gap: 0.25rem; }

nav a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 0.875rem;
  font-weight: 500;
  padding: 0.4rem 0.75rem;
  border-radius: var(--radius-sm);
  transition: color 0.15s, background 0.15s;
}

nav a:hover { color: var(--text); background: rgba(255,255,255,0.05); }
nav a.active { color: var(--text); }

/* ── Sections ── */
section {
  max-width: 900px;
  margin: 0 auto;
  padding: 96px clamp(1rem, 5vw, 2rem);
}

.section-label {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--accent-light);
  margin-bottom: 1rem;
}

.section-label::before {
  content: "";
  display: block;
  width: 18px;
  height: 1.5px;
  background: var(--accent-light);
  border-radius: 2px;
}

h2 {
  font-size: clamp(1.6rem, 3.5vw, 2rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.6rem;
}

.section-desc {
  color: var(--text-secondary);
  font-size: 0.97rem;
  max-width: 560px;
  margin-bottom: 2.5rem;
  line-height: 1.8;
}

/* ── Hero ── */
#hero {
  min-height: calc(100vh - 58px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding-top: 0;
  padding-bottom: 4rem;
}

.hero-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 0.82rem;
  font-weight: 500;
  color: var(--accent-light);
  background: var(--accent-glow);
  border: 1px solid rgba(99, 102, 241, 0.25);
  border-radius: 100px;
  padding: 0.35rem 0.9rem;
  margin-bottom: 2rem;
  width: fit-content;
}

.hero-eyebrow-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 8px #22c55e;
  animation: pulse-dot 2.2s ease-in-out infinite;
}

@keyframes pulse-dot {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.4; }
}

#hero h1 {
  font-size: clamp(2.6rem, 7vw, 4.2rem);
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.04em;
  margin-bottom: 1.5rem;
}

#hero h1 .highlight {
  background: linear-gradient(135deg, #818cf8 0%, #6366f1 50%, #a78bfa 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

#hero .hero-sub {
  font-size: 1.05rem;
  color: var(--text-secondary);
  max-width: 580px;
  margin-bottom: 2.5rem;
  line-height: 1.85;
}

.hero-actions { display: flex; gap: 0.75rem; flex-wrap: wrap; margin-bottom: 3.5rem; }

.hero-stats {
  display: flex;
  gap: 2.5rem;
  flex-wrap: wrap;
  padding-top: 2.5rem;
  border-top: 1px solid var(--border);
}

.stat-item .stat-num {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -0.04em;
  color: var(--text);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.stat-item .stat-label {
  font-size: 0.82rem;
  color: var(--text-muted);
  font-weight: 400;
}

/* ── Buttons ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.65rem 1.3rem;
  border-radius: var(--radius-sm);
  font-size: 0.9rem;
  font-weight: 600;
  text-decoration: none;
  transition: all 0.2s ease;
  border: 1px solid transparent;
  cursor: pointer;
  font-family: inherit;
}

.btn-primary {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
  box-shadow: 0 1px 3px rgba(99,102,241,0.3);
}

.btn-primary:hover {
  background: var(--accent-light);
  border-color: var(--accent-light);
  transform: translateY(-1px);
  box-shadow: 0 4px 16px rgba(99,102,241,0.35);
}

.btn-outline {
  background: transparent;
  color: var(--text-secondary);
  border-color: var(--border);
}

.btn-outline:hover {
  border-color: var(--border-hover);
  color: var(--text);
  background: rgba(255,255,255,0.04);
  transform: translateY(-1px);
}

/* ── Tag ── */
.tag {
  display: inline-block;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--accent-light);
  background: var(--accent-glow);
  border: 1px solid rgba(99, 102, 241, 0.2);
  border-radius: 100px;
  padding: 0.2rem 0.65rem;
}

/* ── Reference cards (featured) ── */
.ref-list {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

.ref-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

.ref-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

.ref-card-header {
  display: flex;
  align-items: center;
  gap: 1rem;
  padding: 1.4rem 1.6rem;
  border-bottom: 1px solid var(--border);
}

.ref-logo {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  object-fit: contain;
  background: #fff;
  padding: 4px;
  flex-shrink: 0;
}

.ref-logo-placeholder {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background: var(--border);
  flex-shrink: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text-muted);
}

.ref-header-info { flex: 1; min-width: 0; }

.ref-header-top {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-bottom: 0.2rem;
}

.ref-header-top h3 {
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.ref-date {
  font-size: 0.78rem;
  color: var(--text-muted);
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border);
  border-radius: 100px;
  padding: 0.15rem 0.6rem;
  white-space: nowrap;
}

.ref-card-body {
  padding: 1.4rem 1.6rem;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem 2rem;
}

@media (max-width: 640px) {
  .ref-card-body { grid-template-columns: 1fr; }
}

.ref-block-label {
  font-size: 0.7rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.45rem;
}

.ref-block p {
  font-size: 0.875rem;
  color: var(--text-secondary);
  line-height: 1.75;
}

.ref-block.full { grid-column: 1 / -1; }

.ref-stack { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 0.1rem; }

.stack-badge {
  background: rgba(255,255,255,0.05);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 0.25rem 0.65rem;
  font-size: 0.8rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.ref-card-footer {
  padding: 0 1.6rem 1.4rem;
  display: flex;
  gap: 0.6rem;
}


/* ── Screenshots ── */
.ref-screenshots {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  padding: 0 1.6rem 1.2rem;
  scrollbar-width: none;
}

.ref-screenshots::-webkit-scrollbar { display: none; }

.ref-screenshots img {
  height: 200px;
  width: auto;
  border-radius: 8px;
  object-fit: cover;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

/* ── Past experience list ── */
.exp-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.exp-item {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.1rem 1.4rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  transition: border-color 0.2s ease;
}

.exp-item:hover { border-color: var(--border-hover); }

.exp-info { flex: 1; min-width: 0; }

.exp-top {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  flex-wrap: wrap;
  margin-bottom: 0.15rem;
}

.exp-top h3 { font-size: 0.95rem; font-weight: 600; }

.exp-role { font-size: 0.82rem; color: var(--text-muted); }

/* ── Skills ── */
.skills-categories { display: flex; flex-direction: column; gap: 1.5rem; }

.skill-category-label {
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 0.6rem;
}

.skills-row { display: flex; flex-wrap: wrap; gap: 0.5rem; }

.skill-badge {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 0.4rem 0.9rem;
  font-size: 0.865rem;
  font-weight: 500;
  color: var(--text-secondary);
  transition: border-color 0.15s, color 0.15s;
}

.skill-badge:hover {
  border-color: var(--accent);
  color: var(--accent-light);
}

/* ── Contact ── */
#contact { text-align: center; }

.contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 3rem 2rem;
  max-width: 540px;
  margin: 0 auto;
}

.contact-card p {
  color: var(--text-secondary);
  font-size: 1rem;
  margin-bottom: 2rem;
  line-height: 1.75;
}

.contact-links { display: flex; gap: 0.75rem; justify-content: center; flex-wrap: wrap; }

/* ── Footer ── */
footer {
  text-align: center;
  padding: 2rem;
  color: var(--text-muted);
  font-size: 0.8rem;
  border-top: 1px solid var(--border);
}

/* ── Fade-in ── */
.fade-in {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.4s ease, transform 0.4s ease;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── Responsive misc ── */
@media (max-width: 600px) {
  nav ul { gap: 0; }
  nav ul li:nth-child(n+3) { display: none; }
  h2 { font-size: 1.5rem; }
  .hero-stats { gap: 1.5rem; }
  .ref-card-header { flex-wrap: wrap; }
}

/* ── Sub pages ── */
.page-hero { padding-top: 72px; padding-bottom: 48px; }

.page-hero h1 {
  font-size: clamp(2rem, 5vw, 2.8rem);
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.035em;
  margin-bottom: 1rem;
}

.page-hero .hero-sub {
  font-size: 1rem;
  color: var(--text-secondary);
  max-width: 580px;
  line-height: 1.8;
}

.page-hero + section { padding-top: 0; }

.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-bottom: 1.5rem;
}

.breadcrumb a { color: var(--text-muted); text-decoration: none; }
.breadcrumb a:hover { color: var(--text); }

/* ── Apps grid ── */
.apps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1rem;
}

.app-card {
  display: flex;
  flex-direction: column;
  gap: 0.9rem;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.4rem;
  color: inherit;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease, box-shadow 0.2s ease;
}

a.app-card:hover {
  border-color: var(--border-hover);
  transform: translateY(-3px);
  box-shadow: 0 8px 32px rgba(0,0,0,0.4);
}

.app-card-top { display: flex; align-items: center; gap: 0.9rem; }

.app-card h3 { font-size: 1rem; font-weight: 700; letter-spacing: -0.02em; }

.app-card p { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.7; flex: 1; }

.app-card-meta { display: flex; flex-wrap: wrap; gap: 0.4rem; align-items: center; }

.app-card .more { font-size: 0.82rem; font-weight: 600; color: var(--accent-light); }

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  font-size: 0.72rem;
  font-weight: 600;
  border-radius: 100px;
  padding: 0.2rem 0.65rem;
  border: 1px solid;
}

.status::before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.status-live { color: #4ade80; background: rgba(34,197,94,0.1); border-color: rgba(34,197,94,0.25); }
.status-dev  { color: #fbbf24; background: rgba(245,158,11,0.1); border-color: rgba(245,158,11,0.25); }
.status-done { color: var(--text-muted); background: rgba(255,255,255,0.04); border-color: var(--border); }

.section-more { margin-top: 1.5rem; }

/* ── App page ── */
.app-hero-top { display: flex; align-items: center; gap: 1.1rem; margin-bottom: 1.25rem; }

.app-hero-top .ref-logo { width: 64px; height: 64px; border-radius: 14px; }

.app-hero-top h1 { margin-bottom: 0.3rem; }

.app-links { display: flex; gap: 0.6rem; flex-wrap: wrap; margin-top: 2rem; }

.app-screens {
  display: flex;
  gap: 0.75rem;
  overflow-x: auto;
  scrollbar-width: none;
}

.app-screens::-webkit-scrollbar { display: none; }

.app-screens img {
  height: 360px;
  width: auto;
  border-radius: 12px;
  border: 1px solid var(--border);
  flex-shrink: 0;
}

/* ── Legal / support pages ── */
.prose { max-width: 720px; }

.prose .card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.6rem;
  margin-bottom: 1rem;
}

.prose h2 { font-size: 1.05rem; margin-bottom: 0.6rem; letter-spacing: -0.02em; }

.prose p, .prose li { font-size: 0.93rem; color: var(--text-secondary); line-height: 1.8; }

.prose p + p { margin-top: 0.8rem; }

.prose ul { padding-left: 1.2rem; }

.prose a:not(.btn) { color: var(--accent-light); }

.prose .meta { font-size: 0.82rem; color: var(--text-muted); margin-bottom: 1.5rem; }

footer a { color: var(--text-muted); }
footer a:hover { color: var(--text); }

@media (max-width: 600px) {
  .app-screens img { height: 280px; }
}

.card-action { margin-top: 1.4rem; }

.page-hero.centered { text-align: center; }
.page-hero.centered .hero-sub { margin: 0 auto 2rem; }
.page-hero.centered .hero-actions { justify-content: center; }
