/*
  JJ Portfolio — Styles
  - Modern, minimalist, mobile-first
  - Color palette: Dark blue (#0a192f), Light gray (#e6f1ff), Teal (#64ffda)
  - Fonts: Poppins (600 for headings), Inter (400 body)
*/

/* CSS Reset (light) */
*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; }
html:focus-within { scroll-behavior: smooth; }
html, body { height: 100%; }
body {
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img, picture, svg, video { display: block; max-width: 100%; }
input, button, textarea, select { font: inherit; }

/* Theme Vars */
:root {
  --color-bg: #0a192f;
  --color-text: #e6f1ff;
  --color-accent: #64ffda;
  --color-muted: rgba(230, 241, 255, 0.7);
  --color-card: rgba(100, 255, 218, 0.08);
  --color-card-border: rgba(100, 255, 218, 0.25);

  --container-max: 1120px;
  --radius: 14px;
  --shadow: 0 10px 30px rgba(2, 12, 27, 0.6);
  --shadow-soft: 0 8px 24px rgba(2, 12, 27, 0.35);

  --font-heading: 'Poppins', system-ui, -apple-system, Segoe UI, Roboto, Inter, Arial, sans-serif;
  --font-body: 'Inter', system-ui, -apple-system, Segoe UI, Roboto, Arial, sans-serif;
}

/* Base */
body {
  background: radial-gradient(1200px 800px at 80% -10%, rgba(100,255,218,0.08), transparent 60%),
              radial-gradient(1000px 600px at -10% 0%, rgba(100,255,218,0.05), transparent 60%),
              var(--color-bg);
  color: var(--color-text);
  font-family: var(--font-body);
  line-height: 1.7;
}

.container {
  width: min(92%, var(--container-max));
  margin-inline: auto;
}

a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; text-underline-offset: 3px; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(10, 25, 47, 0.7);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid rgba(100,255,218,0.15);
}
.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
}
.brand {
  font-family: var(--font-heading);
  font-weight: 600;
  letter-spacing: 0.5px;
  color: var(--color-accent);
  border: 1px solid var(--color-accent);
  padding: 6px 10px;
  border-radius: 8px;
}

.site-nav ul { list-style: none; display: flex; gap: 20px; }
.site-nav a { color: var(--color-text); opacity: 0.9; }
.site-nav a:hover { color: var(--color-accent); opacity: 1; text-decoration: none; }

.nav-toggle {
  display: inline-flex;
  flex-direction: column;
  gap: 4px;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 8px;
  color: var(--color-text);
}
.nav-toggle-line {
  width: 22px; height: 2px; background: currentColor; border-radius: 2px;
}
@media (min-width: 768px) {
  .nav-toggle { display: none; }
}

.site-nav { position: fixed; inset: 64px 0 auto 0; background: rgba(10,25,47,0.95); transform: translateY(-120%); transition: transform 260ms ease; }
.site-nav ul { padding: 16px 24px; flex-direction: column; }
.site-nav[aria-expanded="true"] { transform: translateY(0); }
@media (min-width: 768px) {
  .site-nav { position: static; transform: none; background: transparent; }
  .site-nav ul { padding: 0; flex-direction: row; }
}

/* Sections */
.section { padding: 96px 0; }
.section-header { margin-bottom: 28px; }
.section h2 { font-family: var(--font-heading); font-weight: 600; letter-spacing: 0.3px; font-size: clamp(22px, 4vw, 32px); }
.section-subtitle { color: var(--color-muted); max-width: 680px; margin-top: 8px; }

/* Hero */
.hero { padding-top: 120px; }
.hero-inner { display: grid; align-items: center; gap: 40px; grid-template-columns: 1fr; }
.hero-title { font-family: var(--font-heading); font-weight: 600; font-size: clamp(40px, 7vw, 64px); color: var(--color-text); }
.hero-subtitle { color: var(--color-muted); margin-top: 10px; font-size: clamp(16px, 2.6vw, 20px); }
.hero-cta { display: flex; gap: 14px; margin-top: 22px; flex-wrap: wrap; }
.hero-art { width: min(420px, 90%); justify-self: center; opacity: 0.9; }

/* Profile Picture Styling */
.profile-container {
  position: relative;
  width: 200px;
  height: 200px;
  margin: 0 auto;
}

.profile-container::before {
  content: '';
  position: absolute;
  top: -8px;
  left: -8px;
  right: -8px;
  bottom: -8px;
  background: linear-gradient(45deg, var(--color-accent), rgba(230, 241, 255, 0.3));
  border-radius: 50%;
  z-index: -1;
  opacity: 0.3;
}

.profile-container::after {
  content: '';
  position: absolute;
  top: -4px;
  left: -4px;
  right: -4px;
  bottom: -4px;
  background: linear-gradient(45deg, rgba(100, 255, 218, 0.2), rgba(230, 241, 255, 0.1));
  border-radius: 50%;
  z-index: -2;
  opacity: 0.4;
}

.profile-pic {
  width: 100%;
  height: 100%;
  border-radius: 50%;
  object-fit: cover;
  border: 3px solid var(--color-accent);
  box-shadow: 0 8px 32px rgba(100, 255, 218, 0.3);
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.profile-pic:hover {
  transform: scale(1.05);
  box-shadow: 0 12px 40px rgba(100, 255, 218, 0.4);
}
@media (min-width: 920px) {
  .hero-inner { grid-template-columns: 1.1fr 0.9fr; }
  .hero { padding-top: 140px; }
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 18px;
  border-radius: 999px;
  border: 1px solid transparent;
  cursor: pointer;
  text-decoration: none;
  transition: transform 160ms ease, box-shadow 160ms ease, background 160ms ease, color 160ms ease, border-color 160ms ease;
}
.btn-primary { background: var(--color-accent); color: #0b192f; font-weight: 600; }
.btn-primary:hover { transform: translateY(-2px); box-shadow: var(--shadow-soft); }
.btn-secondary { border-color: var(--color-accent); color: var(--color-accent); background: transparent; }
.btn-secondary:hover { background: rgba(100,255,218,0.1); transform: translateY(-2px); box-shadow: var(--shadow-soft); }
.btn-ghost { color: var(--color-text); border-color: rgba(230,241,255,0.2); }
.btn-ghost:hover { border-color: var(--color-accent); color: var(--color-accent); transform: translateY(-2px); }

/* Skills */
.skills { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 18px; }
.tag {
  display: inline-block;
  padding: 8px 12px;
  border-radius: 999px;
  border: 1px solid rgba(230,241,255,0.22);
  background: rgba(255,255,255,0.02);
  color: var(--color-text);
}

/* Projects */
.projects-grid { display: grid; gap: 22px; grid-template-columns: 1fr; }
@media (min-width: 620px) { .projects-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .projects-grid { grid-template-columns: repeat(3, 1fr); } }

.card {
  background: linear-gradient(180deg, rgba(100,255,218,0.06), rgba(255,255,255,0.02));
  border: 1px solid var(--color-card-border);
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: transform 180ms ease, box-shadow 180ms ease;
}
.card:hover { transform: translateY(-6px); box-shadow: 0 16px 40px rgba(2, 12, 27, 0.6); }
.card-media { aspect-ratio: 16/9; background: var(--color-card); display:flex; align-items:center; justify-content:center; }
.card-body { padding: 16px; }
.card-title { font-family: var(--font-heading); font-weight: 600; font-size: 20px; }
.card-text { color: var(--color-muted); margin-top: 6px; min-height: 44px; }
.tech-list { list-style: none; display: flex; flex-wrap: wrap; gap: 10px; margin: 12px 0 10px; padding: 0; }
.tech-list li { font-size: 12px; color: var(--color-accent); border: 1px solid rgba(100,255,218,0.25); padding: 6px 10px; border-radius: 999px; }
.card-actions { margin-top: 8px; display: flex; gap: 10px; }

/* Contact */
.contact-content { display: grid; gap: 24px; grid-template-columns: 1fr; align-items: start; }
@media (min-width: 900px) { .contact-content { grid-template-columns: 1fr 1fr; } }
.socials { display: inline-flex; gap: 14px; margin-top: 16px; }
.socials a { color: var(--color-text); opacity: 0.9; border: 1px solid rgba(230,241,255,0.2); padding: 10px; border-radius: 999px; display:inline-flex; }
.socials a:hover { color: var(--color-accent); border-color: var(--color-accent); }

.contact-form { background: rgba(255,255,255,0.02); border: 1px solid rgba(230,241,255,0.18); border-radius: var(--radius); padding: 18px; box-shadow: var(--shadow-soft); }
.form-row { display: grid; gap: 6px; margin-bottom: 12px; }
.form-row label { font-weight: 500; color: var(--color-text); }
.form-row input, .form-row textarea {
  background: rgba(255,255,255,0.04);
  border: 1px solid rgba(230,241,255,0.2);
  border-radius: 10px;
  padding: 10px 12px;
  color: var(--color-text);
}
.form-row input::placeholder, .form-row textarea::placeholder { color: rgba(230,241,255,0.55); }
.form-row input:focus, .form-row textarea:focus { outline: none; border-color: var(--color-accent); box-shadow: 0 0 0 3px rgba(100,255,218,0.15); }

/* Footer */
.site-footer { border-top: 1px solid rgba(100,255,218,0.15); padding: 22px 0; margin-top: 32px; color: var(--color-muted); text-align:center; }

/* Reveal on scroll */
.reveal { opacity: 0; transform: translateY(10px); transition: opacity 500ms ease, transform 500ms ease; }
.reveal.visible { opacity: 1; transform: none; }

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  html:focus-within { scroll-behavior: auto; }
  .btn, .card, .reveal { transition: none; }
}


