:root {
  --bg: #0a0a0f;
  --bg-elevated: #12121a;
  --text: #e8e8f0;
  --text-muted: #9a9ab0;
  --accent-purple: #8b5cf6;
  --accent-cyan: #22d3ee;
  --gradient: linear-gradient(135deg, var(--accent-purple), var(--accent-cyan));
  --border: rgba(255, 255, 255, 0.08);
  --radius: 12px;
  --container-width: 1100px;
}

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

html {
  scroll-padding-top: 110px;
}

body {
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Inter, Helvetica, Arial, sans-serif;
  line-height: 1.5;
}

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

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

a { color: var(--accent-cyan); text-decoration: none; }
a:hover { text-decoration: underline; }

h1, h2, h3 { line-height: 1.2; }

.site-header {
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  background: rgba(10, 10, 15, 0.85);
  backdrop-filter: blur(8px);
  z-index: 10;
}

.header-inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 16px;
  padding-bottom: 16px;
}

.logo { font-weight: 700; font-size: 1.1rem; display: flex; align-items: center; gap: 10px; }
.logo-icon { height: 26px; width: auto; display: block; }

.site-nav { display: flex; gap: 24px; align-items: center; }
.site-nav a { color: var(--text-muted); }
.site-nav a:hover { color: var(--text); text-decoration: none; }
.site-nav .nav-cta {
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 6px 14px;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 0;
  color: var(--text-muted);
  font-size: 0.9rem;
  text-align: center;
}
.site-footer .legal { margin-top: 4px; }

.btn {
  display: inline-block;
  padding: 12px 24px;
  border-radius: var(--radius);
  font-weight: 600;
  cursor: pointer;
  border: 1px solid transparent;
}
.btn-primary {
  background: var(--gradient);
  color: #0a0a0f;
}
.btn-ghost {
  background: transparent;
  color: var(--text);
  border-color: var(--border);
}
.btn:hover { text-decoration: none; opacity: 0.9; }

.hero {
  padding: 120px 0 100px;
  text-align: center;
}
.hero h1 {
  font-size: clamp(2rem, 5vw, 3.25rem);
  font-weight: 800;
  max-width: 800px;
  margin: 0 auto 24px;
}
.hero-sub {
  color: var(--text-muted);
  font-size: 1.15rem;
  max-width: 560px;
  margin: 0 auto 36px;
}
.hero-actions { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }

.services, .portfolio, .about, .contact { padding: 80px 0; }
.services h2, .portfolio h2, .about h2, .contact h2 {
  font-size: 1.75rem;
  margin-bottom: 40px;
  text-align: center;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 24px;
}

.card {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 28px;
  transition: border-color 0.2s, box-shadow 0.2s, transform 0.2s;
}
.card:hover {
  border-color: var(--accent-cyan);
  box-shadow: 0 0 24px rgba(139, 92, 246, 0.25);
  transform: translateY(-2px);
}
.card h3 { margin-bottom: 12px; font-size: 1.1rem; }
.card p { color: var(--text-muted); font-size: 0.95rem; }

.portfolio-card img {
  width: 100%;
  aspect-ratio: 1200 / 654;
  object-fit: contain;
  border-radius: calc(var(--radius) - 4px);
  background: var(--bg);
  margin-bottom: 16px;
  border: 1px solid var(--border);
}
.portfolio-card h3 { margin-bottom: 8px; }
.portfolio-card a { font-weight: 600; }

.about-inner { text-align: center; }
.about-inner p {
  max-width: 640px;
  margin: 0 auto;
  color: var(--text-muted);
  font-size: 1.05rem;
}

.contact-inner { max-width: 520px; margin: 0 auto; text-align: center; }
.contact-sub { color: var(--text-muted); margin-bottom: 32px; }
#contact-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  text-align: left;
}
#contact-form label { font-size: 0.9rem; color: var(--text-muted); margin-top: 12px; }
#contact-form input, #contact-form textarea {
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 10px 14px;
  color: var(--text);
  font-family: inherit;
  font-size: 1rem;
}
#contact-form input:focus, #contact-form textarea:focus {
  outline: none;
  border-color: var(--accent-cyan);
}
#contact-form button { margin-top: 20px; align-self: center; }
.form-status { margin-top: 16px; font-size: 0.9rem; min-height: 1.2em; }
.form-status-error { color: #f87171; }
.form-status-success { color: #4ade80; }

@media (max-width: 640px) {
  .header-inner { flex-direction: column; gap: 12px; padding-top: 12px; padding-bottom: 12px; }
  .site-nav { gap: 14px; flex-wrap: wrap; justify-content: center; }
  .hero { padding: 80px 0 60px; }
  .hero-actions { flex-direction: column; align-items: center; }
  .services, .portfolio, .about, .contact { padding: 56px 0; }
  .card-grid { grid-template-columns: 1fr; }
}
