:root {
  --bg: #0a0b0f;
  --bg-alt: #0f1117;
  --surface: #14161d;
  --border: #23262f;
  --text: #f2f3f5;
  --text-dim: #a3a7b3;
  --accent: #4f9dff;
  --accent-dim: #1c3a5e;
  --radius: 12px;
  --max-width: 1120px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 24px;
}

a { color: inherit; text-decoration: none; }

/* Header */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  background: transparent;
  border-bottom: 1px solid transparent;
  transition: background 0.3s ease, border-color 0.3s ease, backdrop-filter 0.3s ease;
}

.site-header.scrolled {
  background: rgba(10, 11, 15, 0.6);
  backdrop-filter: blur(16px) saturate(150%);
  -webkit-backdrop-filter: blur(16px) saturate(150%);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 72px;
  gap: 24px;
}

.logo {
  font-weight: 800;
  font-size: 1.1rem;
  letter-spacing: -0.02em;
  flex-shrink: 0;
}

.nav {
  display: flex;
  gap: 32px;
  margin: 0 auto;
  font-size: 0.95rem;
  font-weight: 500;
  color: var(--text-dim);
}

.nav a:hover { color: var(--text); }

.nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 36px;
  height: 36px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
}

.nav-toggle span {
  display: block;
  height: 2px;
  width: 100%;
  background: var(--text);
  border-radius: 2px;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 22px;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.15s ease, opacity 0.15s ease, background 0.15s ease;
  white-space: nowrap;
}

.btn:hover { transform: translateY(-1px); }

.btn-primary {
  background: var(--accent);
  color: #06101f;
}

.btn-primary:hover { opacity: 0.9; }

.btn-ghost {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-ghost:hover { border-color: var(--accent); }

.btn-small {
  padding: 9px 18px;
  font-size: 0.875rem;
  flex-shrink: 0;
}

/* Hero */
.hero {
  padding: 200px 0 120px;
  background:
    radial-gradient(ellipse 60% 50% at 50% -10%, var(--accent-dim), transparent);
}

.hero-inner {
  max-width: 780px;
}

.hero h1 {
  font-size: clamp(2.2rem, 5vw, 3.4rem);
  font-weight: 800;
  letter-spacing: -0.03em;
  line-height: 1.1;
  margin: 0 0 24px;
}

.hero-sub {
  font-size: 1.15rem;
  color: var(--text-dim);
  max-width: 600px;
  margin: 0 0 36px;
}

.hero-actions {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

/* Sections */
section { padding: 96px 0; }

.section-title {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  margin: 0 0 8px;
}

.section-sub {
  color: var(--text-dim);
  margin: 0 0 40px;
}

.work .section-title { margin-bottom: 8px; }

.services .section-title { margin-bottom: 40px; }

/* Grid / cards */
.grid { display: grid; gap: 20px; }

.grid-3 { grid-template-columns: repeat(3, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
}

.card-icon {
  font-size: 1.6rem;
  margin-bottom: 14px;
}

.card h3 {
  margin: 0 0 10px;
  font-size: 1.1rem;
  font-weight: 700;
}

.card p {
  margin: 0;
  color: var(--text-dim);
  font-size: 0.95rem;
}

.tag {
  display: inline-block;
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--accent);
  background: var(--accent-dim);
  padding: 4px 12px;
  border-radius: 999px;
  margin-bottom: 14px;
}

.work .card p { color: var(--text-dim); }

/* Contact */
.contact {
  background: var(--bg-alt);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  text-align: center;
}

.contact-inner {
  max-width: 560px;
}

.contact h2 {
  font-size: clamp(1.6rem, 3vw, 2.1rem);
  font-weight: 800;
  margin: 0 0 12px;
}

.contact p {
  color: var(--text-dim);
  margin: 0 0 32px;
}

/* Footer */
.site-footer {
  padding: 32px 0;
}

.footer-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  color: var(--text-dim);
  font-size: 0.9rem;
  flex-wrap: wrap;
  gap: 12px;
}

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

/* Responsive */
@media (max-width: 860px) {
  .grid-3 { grid-template-columns: repeat(2, 1fr); }
}

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

  .nav {
    position: absolute;
    top: 72px;
    left: 0;
    right: 0;
    flex-direction: column;
    gap: 0;
    background: rgba(10, 11, 15, 0.95);
    backdrop-filter: blur(16px);
    border-bottom: 1px solid var(--border);
    padding: 8px 24px 16px;
    display: none;
  }

  .nav.open { display: flex; }

  .nav a {
    padding: 12px 0;
    border-bottom: 1px solid var(--border);
  }

  .nav a:last-child { border-bottom: none; }

  .btn-small { display: none; }

  .nav-toggle { display: flex; }

  .hero { padding: 140px 0 80px; }
}
