/* ==========================================================================
   Ecom Pro — Dark-only theme. Ported from React/Tailwind design system.
   ========================================================================== */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@400;500;600;700&family=Inter:wght@300;400;500;600;700&display=swap');

:root {
  --background: 222 47% 5%;
  --foreground: 210 40% 98%;
  --card: 222 40% 8%;
  --card-foreground: 210 40% 98%;
  --primary: 158 90% 50%;
  --primary-foreground: 222 47% 5%;
  --primary-glow: 158 100% 60%;
  --secondary: 222 30% 12%;
  --muted: 222 30% 12%;
  --muted-foreground: 215 20% 65%;
  --border: 222 30% 15%;
  --input: 222 30% 15%;
  --ring: 158 90% 50%;
  --radius: 1rem;

  --gradient-hero: radial-gradient(ellipse 80% 60% at 50% 0%, hsl(158 90% 50% / 0.2), transparent 70%);
  --gradient-primary: linear-gradient(135deg, hsl(158 90% 50%), hsl(170 100% 60%));
  --gradient-text: linear-gradient(135deg, hsl(210 40% 98%), hsl(158 90% 60%));
  --gradient-card: linear-gradient(145deg, hsl(222 40% 9%), hsl(222 40% 6%));

  --shadow-md: 0 8px 24px -8px hsl(0 0% 0% / 0.5);
  --shadow-glow: 0 0 80px hsl(158 100% 60% / 0.4);
  --shadow-elegant: 0 20px 60px -20px hsl(158 100% 60% / 0.3);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: 'Inter', system-ui, sans-serif;
  background: hsl(var(--background));
  color: hsl(var(--foreground));
  line-height: 1.6;
  font-feature-settings: "ss01", "cv11";
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button { font: inherit; cursor: pointer; border: 0; background: none; color: inherit; }
h1, h2, h3, h4, h5, h6 { font-family: 'Space Grotesk', system-ui, sans-serif; letter-spacing: -0.02em; line-height: 1.1; font-weight: 700; }
::selection { background: hsl(var(--primary) / 0.3); color: hsl(var(--foreground)); }

.container { width: 100%; max-width: 1280px; margin: 0 auto; padding: 0 1.5rem; }
.section { padding: 6rem 0; position: relative; }
.section-sm { padding: 4rem 0; }

/* Buttons */
.btn { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.75rem 1.5rem; border-radius: 0.75rem; font-weight: 600; font-size: 0.95rem; transition: all .3s cubic-bezier(.65,0,.35,1); white-space: nowrap; }
.btn-hero { background: var(--gradient-primary); color: hsl(var(--primary-foreground)); box-shadow: var(--shadow-glow); }
.btn-hero:hover { transform: translateY(-2px); box-shadow: 0 0 100px hsl(158 100% 60% / 0.6); }
.btn-glow { background: hsl(var(--secondary)); color: hsl(var(--foreground)); border: 1px solid hsl(var(--border)); }
.btn-glow:hover { border-color: hsl(var(--primary)); color: hsl(var(--primary)); }
.btn-xl { padding: 1rem 2rem; font-size: 1rem; border-radius: 1rem; }
.btn-sm { padding: 0.5rem 1rem; font-size: 0.85rem; }

/* Glass */
.glass {
  background: hsl(var(--background) / 0.7);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  border: 1px solid hsl(var(--border) / 0.5);
}

/* Text gradient */
.text-gradient-primary {
  background: var(--gradient-primary);
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent; color: transparent;
}

/* Backgrounds */
.bg-grid {
  background-image:
    linear-gradient(to right, hsl(var(--border) / 0.4) 1px, transparent 1px),
    linear-gradient(to bottom, hsl(var(--border) / 0.4) 1px, transparent 1px);
  background-size: 60px 60px;
  -webkit-mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
          mask-image: radial-gradient(ellipse at center, black 30%, transparent 70%);
}

/* ============ NAVBAR ============ */
.site-header { position: fixed; top: 0; left: 0; right: 0; z-index: 50; transition: padding .5s; padding: 1.25rem 0; }
.site-header.scrolled { padding: 0.75rem 0; }
.navbar { display: flex; align-items: center; justify-content: space-between; padding: 0.75rem 1.5rem; border-radius: 1rem; transition: all .5s; }
.site-header.scrolled .navbar { background: hsl(var(--background) / 0.7); backdrop-filter: blur(20px) saturate(180%); border: 1px solid hsl(var(--border) / 0.5); box-shadow: var(--shadow-md); }
.brand { display: flex; align-items: center; gap: 0.6rem; }
.brand-mark { position: relative; width: 2.25rem; height: 2.25rem; border-radius: 0.5rem; background: var(--gradient-primary); display: flex; align-items: center; justify-content: center; color: hsl(var(--primary-foreground)); }
.brand-mark::before { content: ""; position: absolute; inset: -4px; background: var(--gradient-primary); filter: blur(12px); opacity: 0.6; border-radius: 0.75rem; z-index: -1; }
.brand-mark img { max-height: 1.75rem; width: auto; }
.brand-name { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.1rem; letter-spacing: -0.02em; }
.nav-links { display: none; align-items: center; gap: 0.25rem; list-style: none; }
.nav-links a { padding: 0.5rem 1rem; font-size: 0.9rem; font-weight: 500; color: hsl(var(--muted-foreground)); position: relative; transition: color .2s; }
.nav-links a:hover { color: hsl(var(--foreground)); }
.nav-actions { display: flex; align-items: center; gap: 0.5rem; }
.menu-toggle { display: inline-flex; padding: 0.5rem; border-radius: 0.75rem; }
.mobile-menu { display: none; margin-top: 0.5rem; padding: 1rem; border-radius: 1rem; background: hsl(var(--background) / 0.85); backdrop-filter: blur(20px); border: 1px solid hsl(var(--border) / 0.5); }
.mobile-menu.open { display: block; }
.mobile-menu ul { list-style: none; display: flex; flex-direction: column; gap: 0.25rem; }
.mobile-menu a { padding: 0.75rem 1rem; border-radius: 0.5rem; display: block; font-weight: 500; }
.mobile-menu a:hover { background: hsl(var(--secondary)); }

@media (min-width: 1024px) { .nav-links { display: flex; } .menu-toggle { display: none; } }

/* ============ HERO ============ */
.hero { position: relative; min-height: 100vh; display: flex; align-items: center; padding: 8rem 0 5rem; overflow: hidden; }
.hero::before { content: ""; position: absolute; inset: 0; background: var(--gradient-hero); pointer-events: none; }
.hero-grid { display: grid; gap: 3rem; align-items: center; position: relative; }
.hero-pill { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.5rem 1rem; border-radius: 9999px; font-size: 0.85rem; font-weight: 500; }
.hero-pill .dot { position: relative; display: inline-flex; width: 0.5rem; height: 0.5rem; }
.hero-pill .dot::before { content: ""; position: absolute; inset: 0; border-radius: 50%; background: hsl(var(--primary)); opacity: 0.75; animation: ping 1.4s cubic-bezier(0,0,0.2,1) infinite; }
.hero-pill .dot::after { content: ""; position: relative; display: inline-flex; width: 0.5rem; height: 0.5rem; border-radius: 50%; background: hsl(var(--primary)); }
.hero h1 { font-size: clamp(2.5rem, 6vw, 4.5rem); font-weight: 700; line-height: 1.05; margin: 1.5rem 0; }
.hero p.lead { font-size: clamp(1rem, 1.5vw, 1.25rem); color: hsl(var(--muted-foreground)); max-width: 36rem; margin-bottom: 2rem; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 1rem; }
.hero-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 1.5rem; padding-top: 2rem; margin-top: 2rem; border-top: 1px solid hsl(var(--border) / 0.6); max-width: 32rem; }
.hero-stats .v { font-family: 'Space Grotesk', sans-serif; font-size: clamp(1.75rem, 3vw, 2.25rem); font-weight: 700; }
.hero-stats .l { font-size: 0.8rem; color: hsl(var(--muted-foreground)); margin-top: 0.25rem; }
.hero-portrait { position: relative; max-width: 28rem; margin: 0 auto; }
.hero-portrait .glow { position: absolute; inset: -1.5rem; background: var(--gradient-primary); opacity: 0.3; filter: blur(60px); border-radius: 50%; animation: glow-pulse 4s ease-in-out infinite; }
.hero-portrait .frame { position: relative; aspect-ratio: 1/1; border-radius: 1.5rem; overflow: hidden; border: 1px solid hsl(var(--border) / 0.6); background: var(--gradient-card); box-shadow: var(--shadow-elegant); }
.hero-portrait .frame img { width: 100%; height: 100%; object-fit: cover; }
.hero-portrait .frame::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, hsl(var(--background) / 0.8), transparent 50%); }
.float-card { position: absolute; padding: 1rem; border-radius: 1rem; display: flex; align-items: center; gap: 0.75rem; box-shadow: var(--shadow-md); background: hsl(var(--background) / 0.7); backdrop-filter: blur(20px); border: 1px solid hsl(var(--border) / 0.5); }
.float-card .icon { width: 2.5rem; height: 2.5rem; border-radius: 0.75rem; background: hsl(var(--primary) / 0.15); display: flex; align-items: center; justify-content: center; color: hsl(var(--primary)); }
.float-card .label { font-size: 0.75rem; color: hsl(var(--muted-foreground)); }
.float-card .value { font-family: 'Space Grotesk', sans-serif; font-weight: 700; font-size: 1.1rem; }
.float-card.tl { top: -1rem; left: -1rem; animation: float 5s ease-in-out infinite; }
.float-card.br { bottom: -1rem; right: -1rem; animation: float 6s ease-in-out infinite 1s; }

@media (min-width: 1024px) {
  .hero-grid { grid-template-columns: 7fr 5fr; }
}

/* ============ SECTION HEADERS ============ */
.eyebrow { display: inline-flex; align-items: center; gap: 0.5rem; padding: 0.4rem 0.9rem; border-radius: 9999px; background: hsl(var(--primary) / 0.1); border: 1px solid hsl(var(--primary) / 0.3); color: hsl(var(--primary)); font-size: 0.8rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; }
.section-title { font-size: clamp(2rem, 4vw, 3rem); margin: 1rem 0; }
.section-sub { color: hsl(var(--muted-foreground)); max-width: 38rem; margin: 0 auto; font-size: 1.05rem; }
.section-head { text-align: center; margin-bottom: 3.5rem; }

/* ============ GRID + CARDS ============ */
.grid-2 { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
.grid-3 { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
.grid-4 { display: grid; gap: 1.5rem; grid-template-columns: 1fr; }
@media (min-width: 640px) { .grid-2, .grid-3, .grid-4 { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1024px) { .grid-3 { grid-template-columns: repeat(3, 1fr); } .grid-4 { grid-template-columns: repeat(4, 1fr); } }

.card {
  background: var(--gradient-card);
  border: 1px solid hsl(var(--border) / 0.6);
  border-radius: 1.25rem;
  padding: 2rem;
  transition: all .4s cubic-bezier(.65,0,.35,1);
  position: relative;
  overflow: hidden;
}
.card:hover { transform: translateY(-6px); border-color: hsl(var(--primary) / 0.5); box-shadow: var(--shadow-elegant); }
.card .icon-wrap { width: 3rem; height: 3rem; border-radius: 0.85rem; background: hsl(var(--primary) / 0.15); color: hsl(var(--primary)); display: inline-flex; align-items: center; justify-content: center; margin-bottom: 1.25rem; }
.card h3 { font-size: 1.25rem; margin-bottom: 0.75rem; }
.card p { color: hsl(var(--muted-foreground)); font-size: 0.95rem; }

/* Portfolio */
.portfolio-card { padding: 0; border-radius: 1.25rem; overflow: hidden; background: var(--gradient-card); border: 1px solid hsl(var(--border) / 0.6); transition: all .4s; }
.portfolio-card:hover { transform: translateY(-6px); border-color: hsl(var(--primary) / 0.5); box-shadow: var(--shadow-elegant); }
.portfolio-card .thumb { aspect-ratio: 16/10; overflow: hidden; background: hsl(var(--secondary)); }
.portfolio-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: transform .6s; }
.portfolio-card:hover .thumb img { transform: scale(1.05); }
.portfolio-card .body { padding: 1.5rem; }
.portfolio-card .tag { display: inline-block; padding: 0.25rem 0.7rem; background: hsl(var(--primary) / 0.15); color: hsl(var(--primary)); border-radius: 9999px; font-size: 0.7rem; font-weight: 600; text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 0.75rem; }
.portfolio-card h3 { font-size: 1.15rem; margin-bottom: 0.5rem; }
.portfolio-card .metrics { display: flex; gap: 1rem; margin-top: 1rem; padding-top: 1rem; border-top: 1px solid hsl(var(--border) / 0.5); }
.portfolio-card .metrics div { font-size: 0.8rem; color: hsl(var(--muted-foreground)); }
.portfolio-card .metrics strong { display: block; color: hsl(var(--primary)); font-family: 'Space Grotesk', sans-serif; font-size: 1.1rem; font-weight: 700; }

/* Testimonials */
.testimonial { padding: 2rem; background: var(--gradient-card); border: 1px solid hsl(var(--border) / 0.6); border-radius: 1.25rem; }
.testimonial p { font-size: 1.05rem; line-height: 1.6; margin-bottom: 1.5rem; }
.testimonial .who { display: flex; align-items: center; gap: 0.85rem; }
.testimonial .who img { width: 3rem; height: 3rem; border-radius: 50%; object-fit: cover; }
.testimonial .who .name { font-weight: 600; }
.testimonial .who .role { color: hsl(var(--muted-foreground)); font-size: 0.85rem; }

/* Experience */
.timeline { position: relative; max-width: 56rem; margin: 0 auto; }
.timeline::before { content: ""; position: absolute; left: 1rem; top: 0; bottom: 0; width: 2px; background: hsl(var(--border)); }
@media (min-width: 768px) { .timeline::before { left: 50%; transform: translateX(-1px); } }
.tl-item { position: relative; padding-left: 3rem; margin-bottom: 2.5rem; }
.tl-item::before { content: ""; position: absolute; left: 0.55rem; top: 0.5rem; width: 0.95rem; height: 0.95rem; border-radius: 50%; background: hsl(var(--primary)); box-shadow: 0 0 0 4px hsl(var(--background)), 0 0 0 6px hsl(var(--primary) / 0.3); }
@media (min-width: 768px) {
  .tl-item { width: 50%; padding-left: 0; padding-right: 3rem; }
  .tl-item:nth-child(even) { margin-left: 50%; padding-right: 0; padding-left: 3rem; }
  .tl-item::before { left: auto; right: -0.5rem; }
  .tl-item:nth-child(even)::before { left: -0.5rem; right: auto; }
}
.tl-card { padding: 1.5rem; background: var(--gradient-card); border: 1px solid hsl(var(--border) / 0.6); border-radius: 1rem; }
.tl-card .when { color: hsl(var(--primary)); font-size: 0.85rem; font-weight: 600; margin-bottom: 0.4rem; }
.tl-card h3 { font-size: 1.1rem; margin-bottom: 0.25rem; }
.tl-card .co { color: hsl(var(--muted-foreground)); font-size: 0.9rem; margin-bottom: 0.6rem; }

/* Skills */
.skill { margin-bottom: 1.25rem; }
.skill .row { display: flex; justify-content: space-between; margin-bottom: 0.5rem; font-size: 0.9rem; font-weight: 500; }
.skill .bar { height: 0.5rem; background: hsl(var(--secondary)); border-radius: 9999px; overflow: hidden; }
.skill .fill { height: 100%; background: var(--gradient-primary); border-radius: 9999px; width: 0; transition: width 1.5s cubic-bezier(.65,0,.35,1); }

/* Contact */
.contact-grid { display: grid; gap: 2.5rem; grid-template-columns: 1fr; }
@media (min-width: 1024px) { .contact-grid { grid-template-columns: 5fr 7fr; } }
.contact-info .info-row { display: flex; gap: 1rem; align-items: center; padding: 1rem; border-radius: 1rem; background: var(--gradient-card); border: 1px solid hsl(var(--border) / 0.6); margin-bottom: 1rem; }
.contact-info .icon { width: 2.75rem; height: 2.75rem; border-radius: 0.75rem; background: hsl(var(--primary) / 0.15); color: hsl(var(--primary)); display: flex; align-items: center; justify-content: center; flex-shrink: 0; }
.contact-info .label { font-size: 0.75rem; color: hsl(var(--muted-foreground)); text-transform: uppercase; letter-spacing: 0.05em; }
.contact-info .value { font-weight: 600; }
.contact-form { background: var(--gradient-card); border: 1px solid hsl(var(--border) / 0.6); border-radius: 1.5rem; padding: 2rem; }
.contact-form label { display: block; margin-bottom: 0.4rem; font-size: 0.85rem; font-weight: 500; }
.contact-form input, .contact-form textarea, .contact-form select {
  width: 100%; padding: 0.75rem 1rem; background: hsl(var(--input)); border: 1px solid hsl(var(--border)); border-radius: 0.75rem; color: hsl(var(--foreground)); font: inherit; font-size: 0.95rem; margin-bottom: 1rem; transition: border-color .2s;
}
.contact-form input:focus, .contact-form textarea:focus, .contact-form select:focus { outline: none; border-color: hsl(var(--primary)); }
.contact-form textarea { resize: vertical; min-height: 8rem; }
.form-msg { padding: 0.85rem 1rem; border-radius: 0.75rem; margin-bottom: 1rem; font-size: 0.9rem; }
.form-msg.success { background: hsl(var(--primary) / 0.15); color: hsl(var(--primary)); border: 1px solid hsl(var(--primary) / 0.3); }
.form-msg.error { background: hsl(0 70% 50% / 0.15); color: hsl(0 70% 65%); border: 1px solid hsl(0 70% 50% / 0.3); }

/* Floating CTA */
.floating-cta { position: fixed; bottom: 1.5rem; right: 1.5rem; z-index: 40; width: 3.5rem; height: 3.5rem; border-radius: 50%; background: var(--gradient-primary); display: flex; align-items: center; justify-content: center; color: hsl(var(--primary-foreground)); box-shadow: var(--shadow-glow); animation: float 4s ease-in-out infinite; transition: transform .3s; }
.floating-cta:hover { transform: scale(1.1); }

/* Footer */
.site-footer { border-top: 1px solid hsl(var(--border) / 0.6); padding: 2.5rem 0; margin-top: 4rem; }
.site-footer .row { display: flex; flex-direction: column; gap: 1rem; align-items: center; justify-content: space-between; text-align: center; }
.site-footer p { color: hsl(var(--muted-foreground)); font-size: 0.9rem; }
@media (min-width: 768px) { .site-footer .row { flex-direction: row; text-align: left; } }

/* ============ ANIMATIONS ============ */
@keyframes ping { 75%, 100% { transform: scale(2); opacity: 0; } }
@keyframes float { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-12px); } }
@keyframes glow-pulse { 0%, 100% { opacity: 0.3; transform: scale(1); } 50% { opacity: 0.5; transform: scale(1.05); } }
@keyframes fade-in-up { 0% { opacity: 0; transform: translateY(40px); } 100% { opacity: 1; transform: translateY(0); } }

/* AOS lightweight overrides */
[data-aos] { opacity: 0; transition: opacity .8s cubic-bezier(.65,0,.35,1), transform .8s cubic-bezier(.65,0,.35,1); }
[data-aos="fade-up"] { transform: translateY(40px); }
[data-aos="fade-down"] { transform: translateY(-40px); }
[data-aos="fade-left"] { transform: translateX(40px); }
[data-aos="fade-right"] { transform: translateX(-40px); }
[data-aos="zoom-in"] { transform: scale(0.9); }
[data-aos].aos-animate { opacity: 1; transform: none; }

.glow-orb { position: absolute; border-radius: 50%; filter: blur(60px); pointer-events: none; animation: glow-pulse 4s ease-in-out infinite; }
.glow-orb.tl { top: 25%; left: -5rem; width: 24rem; height: 24rem; background: hsl(var(--primary) / 0.2); }
.glow-orb.br { bottom: 25%; right: -5rem; width: 24rem; height: 24rem; background: hsl(var(--primary-glow) / 0.2); animation-delay: 2s; }

/* Filter chips (portfolio) */
.filters { display: flex; flex-wrap: wrap; justify-content: center; gap: 0.5rem; margin-bottom: 2.5rem; }
.filters button { padding: 0.5rem 1.25rem; border-radius: 9999px; background: hsl(var(--secondary)); color: hsl(var(--muted-foreground)); font-size: 0.85rem; font-weight: 500; transition: all .2s; border: 1px solid transparent; }
.filters button:hover { color: hsl(var(--foreground)); }
.filters button.active { background: var(--gradient-primary); color: hsl(var(--primary-foreground)); }

/* Utility */
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.text-center { text-align: center; }
.mt-2 { margin-top: 0.5rem; } .mt-4 { margin-top: 1rem; } .mt-6 { margin-top: 1.5rem; }
