:root {
  --primary: #FF006E;
  --secondary: #FFBE0B;
  --tertiary: #8338EC;
  --bg-dark: #0a0a0a;
  --bg-light: #1a1a1a;
  --text-primary: #ffffff;
  --text-secondary: #c0c0c0;
  --accent: #00F5FF;
  --gradient: linear-gradient(45deg, #FF006E, #FFBE0B, #8338EC, #FF006E);
  --font-main: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  --font-display: 'Syne', sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; height: 100%; margin: 0; padding: 0; }

body {
  background-color: var(--bg-dark);
  color: var(--text-primary);
  font-family: var(--font-main);
  line-height: 1.6;
  overflow-x: hidden;
  min-height: 100vh;
  margin: 0; padding: 0;
}

/* Noise texture for depth */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  opacity: 0.035;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='300' height='300'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.75' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='300' height='300' filter='url(%23n)' opacity='1'/%3E%3C/svg%3E");
  background-repeat: repeat;
  background-size: 300px 300px;
  pointer-events: none;
  z-index: 0;
}

h1,h2,h3,h4,h5,h6 { font-family: var(--font-display); font-weight: 700; line-height: 1.2; }

/* ─── NAV ─── */
.header-nav {
  position: fixed; top: 0; left: 0; width: 100%;
  background: rgb(8 8 8 / .98); border-bottom: 1px solid rgba(255,0,110,0.4);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  z-index: 1000; padding: 15px 0;
  border-bottom: 2px solid var(--primary);
  transition: all 0.3s ease; height: 80px;
}
.header-nav.scrolled { padding: 10px 0; background: rgb(10 10 10 / .99); height: 70px; }

.nav-container {
  display: flex; justify-content: space-between; align-items: center;
  max-width: 1200px; margin: 0 auto; padding: 0 20px; height: 100%;
}
.nav-logo { display: flex; align-items: center; text-decoration: none; transition: transform 0.3s ease; }
.nav-logo:hover { transform: scale(1.05); }
.nav-logo img { width: 50px; height: 50px; border-radius: 50%; border: 2px solid var(--primary); transition: border-color 0.3s ease; }
.nav-logo:hover img { border-color: var(--secondary); }
.nav-logo-text {
  margin-left: 15px; font-size: 22px; font-weight: 800;
  font-family: var(--font-display);
  background: var(--gradient); background-size: 200% 200%;
  background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  animation: gradient 3s ease infinite;
  letter-spacing: -0.3px;
}
.nav-links { display: flex; gap: 30px; align-items: center; }
.nav-link {
  color: var(--text-primary); text-decoration: none; font-weight: 500;
  font-size: 15px; position: relative; transition: color 0.3s ease;
  letter-spacing: 0.3px;
}
.nav-link::after {
  content: ''; position: absolute; bottom: -5px; left: 0;
  width: 0; height: 2px; background: var(--primary); transition: width 0.3s ease;
}
.nav-link:hover { color: var(--primary); }
.nav-link:hover::after { width: 100%; }

.mobile-menu-btn {
  display: none; flex-direction: column; justify-content: space-between;
  width: 30px; height: 20px; background: none; border: none; cursor: pointer; padding: 0;
}
.mobile-menu-btn span { display: block; width: 100%; height: 3px; background: var(--text-primary); transition: all 0.3s ease; border-radius: 2px; }
.mobile-menu-btn.active span:nth-child(1) { transform: rotate(45deg) translate(5px,5px); }
.mobile-menu-btn.active span:nth-child(2) { opacity: 0; }
.mobile-menu-btn.active span:nth-child(3) { transform: rotate(-45deg) translate(7px,-6px); }

/* ─── CONTENT / HERO ─── */
.content { position: relative; z-index: 2; margin-top: 0; padding-top: 0; }

.hero-section {
  min-height: 100vh;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  text-align: center; position: relative; overflow: hidden;
  background:
    radial-gradient(ellipse 80% 60% at 20% 50%, rgb(255 0 110 / .07) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 30%, rgb(131 56 236 / .08) 0%, transparent 60%),
    radial-gradient(ellipse 50% 40% at 50% 80%, rgb(255 190 11 / .05) 0%, transparent 60%),
    #0a0a0a;
  padding-top: 80px; margin-top: 0; box-sizing: border-box;
}

.retro-grid {
  position: absolute; width: 100%; height: 100%;
  background-image:
    linear-gradient(rgb(255 0 110 / .08) 1px, transparent 1px),
    linear-gradient(90deg, rgb(255 0 110 / .08) 1px, transparent 1px);
  background-size: 60px 60px;
  animation: grid-move 25s linear infinite;
  mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
  -webkit-mask-image: radial-gradient(ellipse 80% 80% at 50% 50%, black 30%, transparent 100%);
}
@keyframes grid-move { 0%{transform:translate(0,0)} 100%{transform:translate(60px,60px)} }

.hero-content { position: relative; z-index: 2; width: 100%; max-width: 1100px; padding: 0 20px; }

/* Eyebrow */
.hero-eyebrow {
  display: inline-flex; align-items: center; gap: 12px;
  background: rgba(255,0,110,0.1);
  border: 1px solid rgba(255,0,110,0.35);
  border-radius: 50px;
  padding: 8px 22px;
  font-size: 0.8rem; font-weight: 600; letter-spacing: 2px;
  text-transform: uppercase; color: var(--primary);
  margin-bottom: 28px;
  font-family: var(--font-display);
}
.eyebrow-dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--primary);
  display: inline-block;
  animation: eyebrow-pulse 2s ease-in-out infinite;
}
@keyframes eyebrow-pulse { 0%,100%{opacity:1;transform:scale(1)} 50%{opacity:0.4;transform:scale(0.7)} }

/* Platform badges */
.platform-row {
  display: flex; gap: 12px; justify-content: center; flex-wrap: wrap;
  margin: 30px 0 10px;
}
.platform-badge {
  display: inline-flex; align-items: center; gap: 8px;
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50px;
  padding: 8px 16px;
  font-size: 0.85rem; font-weight: 500; color: var(--text-secondary);
  transition: all 0.3s ease;
}
.platform-badge:hover {
  border-color: var(--primary);
  color: var(--text-primary);
  background: rgba(255,0,110,0.1);
  transform: translateY(-2px);
}

/* Web dev nudge */
.webdev-nudge {
  margin-top: 28px;
  font-size: 0.9rem; color: var(--text-secondary);
}
.nudge-link {
  color: var(--secondary); text-decoration: none; font-weight: 600;
  transition: color 0.3s ease;
}
.nudge-link:hover { color: #fff; }

/* ─── GLITCH H1 ─── */
.glitch {
  font-size: clamp(2.8rem, 7vw, 5.5rem);
  font-weight: 900; text-transform: uppercase; position: relative;
  text-shadow: 3px 3px 6px rgb(0 0 0 / .9),
    .05em 0 0 rgb(255 0 110 / .65),
    -.025em -.05em 0 rgb(0 245 255 / .65),
    .025em .05em 0 rgb(255 190 11 / .65);
  filter: drop-shadow(2px 2px 4px rgb(0 0 0 / .8));
  animation: glitch 2s infinite;
  line-height: 1.05;
  letter-spacing: -1px;
}
.glitch::before, .glitch::after {
  content: attr(data-text); position: absolute; top: 0; left: 0; width: 100%; height: 100%;
}
.glitch::before { animation: glitch-1 0.5s infinite; color: var(--accent); z-index: -1; }
.glitch::after  { animation: glitch-2 0.5s infinite; color: var(--primary); z-index: -2; }

@keyframes glitch {
  0%,100%{text-shadow:3px 3px 6px rgb(0 0 0/.9),.05em 0 0 rgb(255 0 110/.65),-.025em -.05em 0 rgb(0 245 255/.65),.025em .05em 0 rgb(255 190 11/.65)}
  25%{text-shadow:3px 3px 6px rgb(0 0 0/.9),-.05em -.025em 0 rgb(255 0 110/.65),.025em .025em 0 rgb(0 245 255/.65),-.05em -.05em 0 rgb(255 190 11/.65)}
  50%{text-shadow:3px 3px 6px rgb(0 0 0/.9),.025em .05em 0 rgb(255 0 110/.65),.05em 0 0 rgb(0 245 255/.65),0 -.05em 0 rgb(255 190 11/.65)}
  75%{text-shadow:3px 3px 6px rgb(0 0 0/.9),-.025em 0 0 rgb(255 0 110/.65),-.025em -.025em 0 rgb(0 245 255/.65),-.025em -.05em 0 rgb(255 190 11/.65)}
}
@keyframes glitch-1 {
  0%,100%{clip:rect(42px,9999px,44px,0);transform:skew(0.03deg)}
  20%{clip:rect(70px,9999px,78px,0);transform:skew(0.4deg)}
  40%{clip:rect(17px,9999px,86px,0);transform:skew(0.83deg)}
  60%{clip:rect(40px,9999px,20px,0);transform:skew(0.01deg)}
  80%{clip:rect(80px,9999px,61px,0);transform:skew(0.13deg)}
}
@keyframes glitch-2 {
  0%,100%{clip:rect(65px,9999px,119px,0);transform:skew(0.03deg)}
  20%{clip:rect(40px,9999px,66px,0);transform:skew(0.9deg)}
  40%{clip:rect(92px,9999px,43px,0);transform:skew(0.46deg)}
  60%{clip:rect(43px,9999px,73px,0);transform:skew(0.24deg)}
  80%{clip:rect(54px,9999px,12px,0);transform:skew(0.72deg)}
}

.hero-subtitle {
  font-size: clamp(1rem, 2.5vw, 1.5rem);
  font-weight: 700; margin: 20px 0 10px;
  color: var(--secondary);
  text-transform: uppercase; letter-spacing: 4px;
  text-shadow: 2px 2px 4px rgb(0 0 0 / .8);
  font-family: var(--font-display);
}
.hero-description {
  font-size: clamp(1rem, 2vw, 1.15rem);
  color: var(--text-secondary); margin-bottom: 10px;
  max-width: 620px; margin-left: auto; margin-right: auto;
  line-height: 1.7;
}

/* ─── BUTTONS ─── */
.cta-container { display: flex; gap: 20px; justify-content: center; flex-wrap: wrap; }

.cta-primary, .cta-secondary {
  padding: 15px 40px; font-size: 15px; font-weight: 700;
  text-decoration: none; text-transform: uppercase; letter-spacing: 1.5px;
  border-radius: 50px; position: relative; overflow: hidden;
  transition: all 0.3s ease; font-family: var(--font-display);
}
.cta-primary { background: var(--primary); color: var(--text-primary); border: 2px solid var(--primary); }
.cta-secondary { background: transparent; color: var(--text-primary); border: 2px solid var(--secondary); }
.cta-primary::before, .cta-secondary::before {
  content: ''; position: absolute; top: 50%; left: 50%;
  width: 0; height: 0; background: var(--secondary);
  transform: translate(-50%,-50%); transition: all 0.3s ease; z-index: -1;
}
.cta-primary:hover::before, .cta-secondary:hover::before { width: 120%; height: 120%; }
.cta-primary:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgb(255 0 110 / .35); }
.cta-secondary:hover { transform: translateY(-3px); box-shadow: 0 10px 30px rgb(255 190 11 / .35); }

.path-button { position: relative; }

/* ─── SCROLL INDICATOR ─── */
.scroll-indicator { position: absolute; bottom: 30px; left: 50%; transform: translateX(-50%); }
.scroll-indicator span {
  display: block; width: 28px; height: 48px;
  border: 2px solid var(--primary); border-radius: 25px; position: relative;
}
.scroll-indicator span::before {
  content: ''; position: absolute; top: 10px; left: 50%;
  width: 5px; height: 5px; background: var(--primary);
  border-radius: 50%; transform: translateX(-50%);
  animation: scroll-down 2s infinite;
}
@keyframes scroll-down { 0%{top:10px;opacity:1} 100%{top:30px;opacity:0} }

/* ─── SECTIONS ─── */
section { padding: 80px 20px; max-width: 1200px; margin: 0 auto; }

/* Section alternation for visual rhythm */
.services-section { background: transparent; }
.portfolio-section { position: relative; }
.portfolio-section::before {
  content: '';
  position: absolute; inset: 0; left: 50%; right: 50%;
  margin-left: -50vw; margin-right: -50vw;
  background: #0f0f0f;
  z-index: -1;
}
.contact-section { background: transparent; }

.section-header { text-align: center; margin-bottom: 60px; }
.section-title {
  font-size: clamp(2rem, 5vw, 3.2rem); font-weight: 900; margin-bottom: 20px;
  background: var(--gradient); background-size: 300% 300%;
  background-clip: text; -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  animation: gradient 4s ease infinite;
  filter: drop-shadow(1px 1px 2px rgb(0 0 0 / .6));
  letter-spacing: -0.5px;
}
.section-subtitle { font-size: clamp(1rem, 2vw, 1.2rem); color: var(--text-secondary); }

@keyframes gradient { 0%,100%{background-position:0% 50%} 50%{background-position:100% 50%} }

/* ─── SERVICE CARDS ─── */
.service-card {
  background: rgba(255,255,255,0.03); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(255,255,255,0.08); border-radius: 20px; padding: 36px;
  position: relative; overflow: hidden; transition: all 0.3s ease;
}
.service-card::before {
  content: ''; position: absolute; top: -2px; left: -2px; right: -2px; bottom: -2px;
  background: var(--gradient); border-radius: 20px; opacity: 0; z-index: -1;
  transition: opacity 0.3s ease;
}
.service-card:hover { transform: translateY(-10px); }
.service-card:hover::before { opacity: 1; }

.service-icon { width: 70px; height: 70px; margin-bottom: 24px; position: relative; }
.icon-bg {
  position: absolute; width: 100%; height: 100%;
  background: var(--gradient); border-radius: 16px; opacity: .15;
  animation: pulse 3s ease infinite;
}
.icon-text { position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%); font-size: 1.8rem; }

@keyframes pulse { 0%,100%{transform:scale(1);opacity:.15} 50%{transform:scale(1.1);opacity:.25} }

.service-card h3 { font-size: 1.35rem; margin-bottom: 12px; font-family: var(--font-display); }
.service-list { list-style: none; }
.service-list li {
  padding: 7px 0; color: var(--text-secondary);
  position: relative; padding-left: 22px; font-size: 0.95rem;
}
.service-list li::before { content: '▸'; position: absolute; left: 0; color: var(--secondary); font-weight: 700; }

/* ─── WEB DEV CALLOUT ─── */
.webdev-callout {
  background: rgba(255,255,255,0.025); backdrop-filter: blur(15px);
  border: 1px solid rgba(255,255,255,0.09); border-radius: 20px;
  padding: 10px; overflow: hidden; position: relative;
}
.webdev-callout::before {
  content: ''; position: absolute; top: 0; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, var(--primary), var(--secondary), var(--tertiary));
}
.webdev-callout-inner {
  display: flex; align-items: center; gap: 30px; padding: 30px 36px;
  flex-wrap: wrap;
}
.webdev-icon { font-size: 2.5rem; flex-shrink: 0; }
.webdev-callout-inner > div { flex: 1; min-width: 200px; }
.webdev-callout-inner h3 { font-size: 1.3rem; margin-bottom: 8px; font-family: var(--font-display); }
.webdev-callout-inner p { color: var(--text-secondary); font-size: 0.95rem; }
.webdev-callout-btn { flex-shrink: 0; white-space: nowrap; }

/* ─── PORTFOLIO ─── */
.portfolio-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 30px;
}
.portfolio-item {
  position: relative; overflow: hidden; border-radius: 20px;
  background: rgba(255,255,255,0.03); backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  border: 1px solid rgba(255,255,255,0.07);
  transition: transform 0.3s ease;
}
.portfolio-item:hover { transform: scale(1.02); }
.portfolio-image { position: relative; height: 250px; overflow: hidden; }
.portfolio-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.portfolio-item:hover .portfolio-image img { transform: scale(1.1); }
.portfolio-overlay {
  position: absolute; top: 0; left: 0; width: 100%; height: 100%;
  background: rgb(131 56 236 / .88); display: flex; align-items: center;
  justify-content: center; opacity: 0; transition: opacity 0.3s ease;
}
.portfolio-item:hover .portfolio-overlay { opacity: 1; }
.view-project {
  color: var(--text-primary); font-weight: 700; text-transform: uppercase;
  letter-spacing: 1px; padding: 10px 22px; border: 2px solid var(--text-primary);
  border-radius: 50px; transition: all 0.3s ease; text-decoration: none;
  font-family: var(--font-display);
}
.view-project:hover { background: var(--text-primary); color: var(--tertiary); }
.portfolio-info { padding: 22px; }
.portfolio-info h3 { font-size: 1.2rem; margin-bottom: 8px; font-family: var(--font-display); }
.portfolio-info p { color: var(--text-secondary); font-size: .88rem; }

/* ─── CONTACT ─── */
.contact-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 30px; margin-bottom: 40px;
}
.contact-card {
  border: 1px solid rgba(255,255,255,0.1); border-radius: 20px; padding: 40px;
  text-align: center; text-decoration: none; color: var(--text-primary);
  transition: all 0.3s ease; position: relative; overflow: hidden;
  backdrop-filter: blur(15px); -webkit-backdrop-filter: blur(15px);
  background: rgba(255,255,255,0.03);
}
.contact-card.facebook { background: url(./images/fbback.webp) no-repeat center center/cover; border-color: #1877F2; }
.contact-card.twitter  { background: url(./images/xback.webp)  no-repeat center center/cover; border-color: #1DA1F2; }
.contact-card.telegram { background: url(./images/tgback.webp) no-repeat center center/cover; border-color: #2196F3; }
.contact-card::before {
  content: ''; position: absolute; top: 0; left: -100%; width: 100%; height: 100%;
  background: linear-gradient(90deg, transparent, rgb(255 0 110 / .2), transparent);
  transition: left 0.5s ease;
}
.contact-card:hover::before { left: 100%; }
.contact-card:hover { transform: translateY(-10px); box-shadow: 0 20px 40px rgb(255 0 110 / .25); }
.contact-icon { margin-bottom: 20px; }
.contact-icon svg { fill: var(--primary); transition: fill 0.3s ease; }
.contact-card:hover .contact-icon svg { fill: var(--secondary); }
.contact-card h3 { font-size: 1.2rem; margin-bottom: 10px; font-family: var(--font-display); }
.contact-card p { color: var(--text-secondary); font-size: 0.9rem; }
.contact-cta { text-align: center; font-size: 1.1rem; color: var(--text-secondary); }

/* ─── FOOTER ─── */
.footer { background: #0d0d0d; border-top: 1px solid rgba(255,0,110,0.3); padding: 40px 20px; text-align: center; }
.footer-content p { margin: 10px 0; color: var(--text-secondary); font-size: 0.9rem; }

/* ─── BACK TO TOP ─── */
.back-to-top {
  position: fixed; bottom: 20px; right: 20px; width: 50px; height: 50px;
  background: var(--primary); color: #fff; border: none; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  text-decoration: none; opacity: 0; visibility: hidden;
  transition: all 0.3s ease; z-index: 1000;
  box-shadow: 0 4px 20px rgb(255 0 110 / .3);
}
.back-to-top.show { opacity: 1 !important; visibility: visible !important; }
.back-to-top:hover { transform: translateY(-3px); box-shadow: 0 6px 25px rgb(255 0 110 / .5); }

/* ─── VISIBILITY FIXES ─── */
section { position: relative; }
#portfolio, #contact { scroll-margin-top: 100px; visibility: visible !important; opacity: 1 !important; }
.services-section, .portfolio-section, .crypto-section, .contact-section {
  opacity: 1 !important; transform: none !important;
}
section[id] { display: block !important; visibility: visible !important; }

/* ─── MOBILE ─── */
@media (max-width: 768px) {
  html { height: auto !important; }
  body {
    background-color: #0a0a0a !important;
    height: auto !important; min-height: 100% !important;
  }
  .nav-links {
    display: none; position: fixed; top: 70px; left: 20px; right: 20px;
    width: calc(100vw - 40px); max-height: 60vh;
    background: rgb(10 10 10 / .97); backdrop-filter: blur(10px);
    border: 2px solid var(--primary); border-radius: 20px;
    flex-direction: column; justify-content: center; align-items: center;
    padding: 30px; gap: 20px;
    box-shadow: 0 20px 40px rgb(0 0 0 / .5); z-index: 9999;
    transition: all 0.3s ease; overflow-y: auto;
  }
  .nav-links.active { display: flex !important; }
  .nav-link { font-size: 18px; padding: 10px 20px; width: 100%; text-align: center; border-radius: 10px; }
  .nav-link:hover { background: rgb(255 0 110 / .15); }
  .mobile-menu-btn { display: flex !important; z-index: 10001; position: relative; }

  .header-nav { padding: 10px 0 !important; height: 70px !important; }
  .nav-logo img { width: 40px !important; height: 40px !important; }
  .nav-logo-text { font-size: 18px !important; }

  .content { margin-top: 0 !important; padding-top: 0 !important; }
  .hero-section {
    min-height: 100vh !important; padding-top: 90px !important;
    padding-bottom: 40px !important; justify-content: flex-start !important;
  }
  .hero-content { margin-top: 20px !important; padding: 0 15px !important; }

  .logo-glow { display: block !important; text-align: center !important; margin: 0 auto 20px auto !important; }

  .cta-container { flex-direction: column !important; align-items: center !important; gap: 15px !important; }
  .cta-primary, .cta-secondary { width: 100% !important; max-width: 300px !important; text-align: center !important; }

  .glitch { font-size: clamp(2.2rem, 10vw, 3.5rem) !important; }
  .hero-subtitle { font-size: 1rem !important; letter-spacing: 2px !important; }

  .webdev-callout-inner { flex-direction: column !important; text-align: center !important; }
  .webdev-callout-btn { width: 100% !important; max-width: 260px !important; text-align: center !important; }

  .platform-row { gap: 8px !important; }
  .platform-badge { font-size: 0.78rem !important; padding: 6px 12px !important; }
}

@media (max-width: 480px) {
  body {
    background-color: #0a0a0a !important;
    min-height: 100vh !important;
  }
  .nav-logo-text { font-size: 16px !important; }
  section { padding: 60px 15px !important; }
  .section-title { font-size: 2rem !important; }
  .service-card, .contact-card { padding: 28px 20px !important; }
  .hero-section { padding-top: 100px !important; justify-content: flex-start !important; }
  .hero-content { padding: 0 15px !important; margin-top: 30px !important; }
  .glitch { font-size: clamp(2rem, 12vw, 3rem) !important; }
  .hero-subtitle { font-size: 0.9rem !important; letter-spacing: 1px !important; }
  .scroll-indicator { display: none !important; }
  .back-to-top { width: 45px !important; height: 45px !important; bottom: 1rem !important; right: 1rem !important; }
  .hero-eyebrow { font-size: 0.72rem !important; padding: 6px 16px !important; }
}