*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }

:root {
  --bg: #0a0a0f;
  --bg2: #111118;
  --surface: #18181f;
  --border: #2a2a35;
  --text: #e8e6f0;
  --text-dim: #8a889a;
  --accent: #6cf5a5;
  --accent2: #3be8b0;
  --accent-glow: rgba(108, 245, 165, 0.15);
  --hot: #f56c9a;
  --blue: #6cb4f5;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'Onest', sans-serif;
  background: var(--bg);
  color: var(--text);
  overflow-x: hidden;
  -webkit-font-smoothing: antialiased;
}

body::before {
  content: '';
  position: fixed; inset: 0;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)' opacity='0.04'/%3E%3C/svg%3E");
  pointer-events: none; z-index: 9999;
}

::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--bg); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 3px; }

nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  padding: 20px 48px;
  display: flex; justify-content: space-between; align-items: center;
  backdrop-filter: blur(20px);
  background: rgba(10, 10, 15, 0.7);
  border-bottom: 1px solid rgba(42, 42, 53, 0.5);
}

.logo {
  font-family: 'Unbounded', sans-serif;
  font-weight: 900; font-size: 1.2rem;
  letter-spacing: -0.02em;
  color: var(--accent); text-decoration: none;
}
.logo span { color: var(--text); font-weight: 300; }

.nav-links { display: flex; gap: 32px; }
.nav-links a {
  color: var(--text-dim); text-decoration: none;
  font-size: 0.85rem; font-weight: 500;
  letter-spacing: 0.03em; text-transform: uppercase;
  transition: color 0.3s; position: relative;
}
.nav-links a::after {
  content: ''; position: absolute; bottom: -4px; left: 0;
  width: 0; height: 2px; background: var(--accent); transition: width 0.3s;
}
.nav-links a:hover { color: var(--accent); }
.nav-links a:hover::after { width: 100%; }

.burger { display: none; cursor: pointer; flex-direction: column; gap: 5px; }
.burger span { display: block; width: 24px; height: 2px; background: var(--text); transition: all 0.3s; }

section { padding: 120px 48px; position: relative; }

.section-label {
  font-size: 0.7rem; text-transform: uppercase;
  letter-spacing: 0.25em; color: var(--accent);
  font-weight: 600; margin-bottom: 16px;
}

.section-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700; letter-spacing: -0.02em;
  margin-bottom: 56px; line-height: 1.15;
}

/* PROJECT ITEMS */
.project-showcase { display: flex; flex-direction: column; gap: 80px; }

.project-item {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 48px; align-items: center;
}
.project-item:nth-child(even) { direction: rtl; }
.project-item:nth-child(even) > * { direction: ltr; }

.project-preview {
  position: relative; border-radius: 16px; overflow: hidden;
  border: 1px solid var(--border); background: var(--surface);
  transition: transform 0.5s cubic-bezier(0.23, 1, 0.32, 1), box-shadow 0.5s;
}
.project-preview:hover {
  transform: translateY(-8px) scale(1.01);
  box-shadow: 0 32px 80px rgba(0,0,0,0.5), 0 0 0 1px rgba(108,245,165,0.2);
}
.project-preview img {
  width: 100%; display: block;
  transition: transform 0.6s cubic-bezier(0.23, 1, 0.32, 1);
}
.project-preview:hover img { transform: scale(1.03); }

.project-preview-glow {
  position: absolute; inset: 0;
  background: linear-gradient(180deg, transparent 60%, rgba(10,10,15,0.8) 100%);
  pointer-events: none;
}

.project-info { padding: 12px 0; }

.project-number-tag {
  font-family: 'Unbounded', sans-serif;
  font-size: 0.7rem; font-weight: 700;
  color: var(--accent); letter-spacing: 0.15em;
  text-transform: uppercase; margin-bottom: 16px;
  display: flex; align-items: center; gap: 10px;
}
.project-number-tag::before {
  content: ''; width: 24px; height: 2px; background: var(--accent);
}

.project-info h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 1.6rem; font-weight: 700;
  margin-bottom: 8px; letter-spacing: -0.01em;
}

.project-url-link {
  font-size: 0.85rem; color: var(--accent);
  margin-bottom: 20px; font-weight: 500;
  display: inline-block; text-decoration: none;
  transition: opacity 0.3s;
}
.project-url-link:hover { opacity: 0.7; }

.project-info .desc {
  font-size: 0.95rem; color: var(--text-dim);
  line-height: 1.7; margin-bottom: 24px;
}

.project-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.project-tags span {
  font-size: 0.7rem; padding: 5px 14px;
  border-radius: 100px;
  background: rgba(108, 245, 165, 0.08);
  color: var(--accent);
  border: 1px solid rgba(108, 245, 165, 0.15);
  font-weight: 500; letter-spacing: 0.02em;
}

.project-item--app { grid-template-columns: 1fr; text-align: center; }

.app-visual {
  display: flex; justify-content: center;
  align-items: center; gap: 24px; padding: 48px 0;
}

.phone-mockup {
  width: 120px; height: 240px; border-radius: 24px;
  border: 2px solid var(--accent); background: var(--surface);
  position: relative;
  display: flex; align-items: center; justify-content: center;
  box-shadow: 0 0 40px rgba(108,245,165,0.08);
  transition: transform 0.4s;
}
.phone-mockup:hover { transform: translateY(-8px); }
.phone-mockup::before {
  content: ''; position: absolute; top: 10px;
  width: 40px; height: 4px; border-radius: 2px; background: var(--border);
}
.phone-mockup .os-icon { font-size: 2rem; opacity: 0.6; }
.phone-mockup--android { border-color: var(--blue); box-shadow: 0 0 40px rgba(108,180,245,0.08); }

/* SERVICES */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 20px;
}
.service-card {
  padding: 36px 28px; border: 1px solid var(--border);
  border-radius: 16px; transition: border-color 0.3s, background 0.3s;
}
.service-card:hover {
  border-color: rgba(108, 245, 165, 0.3);
  background: rgba(24, 24, 31, 0.5);
}
.service-icon { font-size: 2rem; margin-bottom: 20px; display: block; }
.service-card h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 1rem; font-weight: 600; margin-bottom: 12px;
}
.service-card p { font-size: 0.85rem; color: var(--text-dim); line-height: 1.6; }

/* STACK */
#stack { background: var(--bg2); }
.stack-marquee {
  overflow: hidden; padding: 24px 0;
  mask-image: linear-gradient(90deg, transparent, black 10%, black 90%, transparent);
}
.stack-track {
  display: flex; gap: 20px;
  animation: marquee 30s linear infinite; width: max-content;
}
@keyframes marquee {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.stack-item {
  padding: 14px 28px; background: var(--surface);
  border: 1px solid var(--border); border-radius: 100px;
  font-size: 0.85rem; font-weight: 500;
  white-space: nowrap; color: var(--text-dim);
  transition: color 0.3s, border-color 0.3s; cursor: default;
}
.stack-item:hover { color: var(--accent); border-color: var(--accent); }

/* ABOUT */
.about-layout {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 64px; align-items: start;
}
.about-text p {
  font-size: 1rem; line-height: 1.8;
  color: var(--text-dim); margin-bottom: 24px;
}
.about-text p strong { color: var(--text); font-weight: 600; }
.about-highlights { display: flex; flex-direction: column; gap: 20px; }
.highlight {
  padding: 28px; border-left: 3px solid var(--accent);
  background: rgba(108, 245, 165, 0.03);
  border-radius: 0 12px 12px 0;
}
.highlight h4 {
  font-family: 'Unbounded', sans-serif;
  font-size: 0.9rem; font-weight: 600; margin-bottom: 8px;
}
.highlight p { font-size: 0.85rem; color: var(--text-dim); line-height: 1.6; }

/* CONTACT */
#contact { background: var(--bg2); }
.contact-box { max-width: 640px; margin: 0 auto; text-align: center; }
.contact-box p { font-size: 1.05rem; color: var(--text-dim); line-height: 1.7; margin-bottom: 40px; }
.contact-links { display: flex; justify-content: center; gap: 16px; flex-wrap: wrap; }
.contact-link {
  display: inline-flex; align-items: center; gap: 10px;
  padding: 14px 28px; border: 1px solid var(--border); border-radius: 100px;
  color: var(--text); text-decoration: none;
  font-size: 0.9rem; font-weight: 500; transition: all 0.3s;
}
.contact-link:hover {
  border-color: var(--accent); background: var(--accent-glow); color: var(--accent);
}
.contact-link--primary {
  background: var(--accent); color: var(--bg);
  border-color: var(--accent); font-weight: 600;
}
.contact-link--primary:hover {
  background: var(--accent2); color: var(--bg);
  box-shadow: 0 0 32px rgba(108, 245, 165, 0.3);
}

/* CTA BUTTON */
.btn-all-projects {
  display: inline-flex; align-items: center; gap: 12px;
  margin-top: 64px; padding: 18px 36px;
  font-family: 'Unbounded', sans-serif;
  font-size: 0.9rem; font-weight: 600;
  color: var(--bg); background: var(--accent);
  border: none; border-radius: 100px;
  text-decoration: none; cursor: pointer;
  transition: all 0.3s;
}
.btn-all-projects:hover {
  background: var(--accent2);
  box-shadow: 0 0 40px rgba(108, 245, 165, 0.3);
  transform: translateY(-2px);
}
.btn-all-projects svg { transition: transform 0.3s; }
.btn-all-projects:hover svg { transform: translateX(4px); }

.projects-cta { text-align: center; }

footer {
  padding: 40px 48px; border-top: 1px solid var(--border);
  display: flex; justify-content: space-between;
  align-items: center; font-size: 0.8rem; color: var(--text-dim);
}

.reveal {
  opacity: 0; transform: translateY(40px);
  transition: opacity 0.8s cubic-bezier(0.23, 1, 0.32, 1),
              transform 0.8s cubic-bezier(0.23, 1, 0.32, 1);
}
.reveal.visible { opacity: 1; transform: translateY(0); }

/* PAGE HEADER for projects page */
.page-header {
  padding: 140px 48px 60px; position: relative;
}
.page-header .hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(42,42,53,0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42,42,53,0.3) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 70%);
}
.page-header h1 {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900; letter-spacing: -0.03em;
  position: relative; z-index: 1;
}
.page-header h1 em {
  font-style: normal;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.page-header p {
  font-size: 1.1rem; color: var(--text-dim);
  margin-top: 20px; max-width: 560px;
  line-height: 1.7; position: relative; z-index: 1;
}
.back-link {
  display: inline-flex; align-items: center; gap: 8px;
  color: var(--accent); text-decoration: none;
  font-size: 0.85rem; font-weight: 500;
  margin-bottom: 32px; position: relative; z-index: 1;
  transition: opacity 0.3s;
}
.back-link:hover { opacity: 0.7; }

@media (max-width: 900px) {
  .project-item, .project-item:nth-child(even) {
    grid-template-columns: 1fr; direction: ltr;
  }
}
@media (max-width: 768px) {
  nav { padding: 16px 24px; }
  .nav-links {
    display: none;
    position: fixed; top: 60px; left: 0; right: 0;
    background: rgba(10,10,15,0.95); backdrop-filter: blur(20px);
    flex-direction: column; padding: 24px; gap: 20px;
    border-bottom: 1px solid var(--border);
  }
  .nav-links.open { display: flex; }
  .burger { display: flex; }
  .hero, section, .page-header { padding-left: 24px; padding-right: 24px; }
  .hero { padding-top: 120px; }
  .hero-stats { flex-wrap: wrap; gap: 32px; }
  .about-layout { grid-template-columns: 1fr; gap: 40px; }
  footer { flex-direction: column; gap: 12px; text-align: center; }
  .page-header { padding-top: 120px; }
}
@media (max-width: 480px) {
  .hero h1 { font-size: 2.2rem; }
  .hero-stats { gap: 24px; }
  .hero-stat h3 { font-size: 1.6rem; }
  .project-info h3 { font-size: 1.2rem; }
}

.hero {
  min-height: 100vh; display: flex; flex-direction: column;
  justify-content: center; padding: 140px 48px 80px; position: relative;
}
.hero-grid {
  position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(42,42,53,0.3) 1px, transparent 1px),
    linear-gradient(90deg, rgba(42,42,53,0.3) 1px, transparent 1px);
  background-size: 60px 60px;
  mask-image: radial-gradient(ellipse 70% 60% at 50% 40%, black 20%, transparent 70%);
}
.hero-orb {
  position: absolute; border-radius: 50%; filter: blur(120px); opacity: 0.12;
  animation: orbFloat 12s ease-in-out infinite;
}
.hero-orb--1 { background: var(--accent); top: 10%; right: 10%; width: 600px; height: 600px; }
.hero-orb--2 { background: var(--hot); bottom: 10%; left: 5%; width: 400px; height: 400px; animation-delay: -4s; }
.hero-orb--3 { background: var(--blue); top: 50%; left: 40%; width: 500px; height: 500px; opacity: 0.08; animation-delay: -8s; }
@keyframes orbFloat {
  0%, 100% { transform: translate(0, 0) scale(1); }
  33% { transform: translate(30px, -20px) scale(1.05); }
  66% { transform: translate(-20px, 15px) scale(0.95); }
}
.hero-label {
  font-size: 0.75rem; text-transform: uppercase;
  letter-spacing: 0.2em; color: var(--accent);
  margin-bottom: 32px; font-weight: 600;
  display: flex; align-items: center; gap: 12px;
  position: relative; z-index: 1;
}
.hero-label::before { content: ''; width: 32px; height: 2px; background: var(--accent); }
.hero h1 {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2.8rem, 7vw, 6rem);
  font-weight: 900; line-height: 1.05;
  letter-spacing: -0.03em; margin-bottom: 32px;
  position: relative; z-index: 1;
}
.hero h1 em {
  font-style: normal;
  background: linear-gradient(135deg, var(--accent), var(--accent2));
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
}
.hero-desc {
  font-size: 1.15rem; color: var(--text-dim);
  max-width: 560px; line-height: 1.7;
  position: relative; z-index: 1; margin-bottom: 48px;
}
.hero-stats { display: flex; gap: 56px; position: relative; z-index: 1; }
.hero-stat h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 2.2rem; font-weight: 700; color: var(--accent);
}
.hero-stat p {
  font-size: 0.8rem; color: var(--text-dim);
  text-transform: uppercase; letter-spacing: 0.1em; margin-top: 4px;
}
#projects { background: var(--bg2); }
/* SCROLL TO TOP */
.scroll-top {
  position: fixed; bottom: 32px; right: 32px; z-index: 999;
  width: 48px; height: 48px; border-radius: 50%;
  background: var(--accent); color: var(--bg);
  border: none; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  opacity: 0; visibility: hidden;
  transform: translateY(16px);
  transition: opacity 0.3s, visibility 0.3s, transform 0.3s, background 0.3s, box-shadow 0.3s;
  box-shadow: 0 4px 20px rgba(108, 245, 165, 0.25);
}
.scroll-top.visible {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.scroll-top:hover {
  background: var(--accent2);
  box-shadow: 0 0 32px rgba(108, 245, 165, 0.4);
  transform: translateY(-3px);
}
.scroll-top svg {
  width: 22px; height: 22px;
}
 
@media (max-width: 768px) {
  .scroll-top { bottom: 20px; right: 20px; width: 44px; height: 44px; }
}