/* ── Reset & Variables ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg:        #0a192f;
  --bg-light:  #112240;
  --accent:    #64ffda;
  --text:      #ccd6f6;
  --text-dim:  #8892b0;
  --font-mono: 'Courier New', monospace;
  --font-sans: 'Segoe UI', system-ui, sans-serif;
  --nav-h:     70px;
  --max-w:     900px;
}

html { scroll-behavior: smooth; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  line-height: 1.6;
}

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

/* ── Nav ── */
nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  height: var(--nav-h);
  background: rgba(10, 25, 47, 0.92);
  backdrop-filter: blur(8px);
  z-index: 100;
  border-bottom: 1px solid rgba(100, 255, 218, 0.1);
}
.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 2rem;
}
.logo {
  font-family: var(--font-mono);
  font-size: 1.4rem;
  color: var(--accent);
  font-weight: bold;
}
nav ul { list-style: none; display: flex; gap: 2rem; }
nav ul li a {
  font-family: var(--font-mono);
  font-size: 0.85rem;
  color: var(--text);
  transition: color 0.2s;
}
nav ul li a:hover { color: var(--accent); text-decoration: none; }

/* ── Sections ── */
section {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 6rem 2rem;
}

.section-title {
  font-size: 1.6rem;
  font-weight: 700;
  margin-bottom: 2.5rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
  white-space: nowrap;
}
.section-title span {
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--accent);
}
.section-title::after {
  content: '';
  display: block;
  height: 1px;
  width: 100%;
  max-width: 300px;
  background: var(--bg-light);
  border-top: 1px solid rgba(100,255,218,0.15);
  margin-left: 0.5rem;
}

/* ── Hero ── */
#hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  padding-top: var(--nav-h);
  position: relative;
  overflow: hidden;
  background: radial-gradient(ellipse at 72% 50%, rgba(61,27,110,0.18) 0%, transparent 65%);
}
#eva-canvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}
.hero-content {
  max-width: 700px;
  position: relative;
  z-index: 2;
}

/* ── NERV HUD overlay ── */
.eva-hud {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
}
.hud-corner {
  position: absolute;
  width: 22px;
  height: 22px;
  border-color: rgba(100,255,218,0.55);
  border-style: solid;
}
.hud-tl { top: calc(var(--nav-h) + 14px); left: 14px;  border-width: 2px 0 0 2px; }
.hud-tr { top: calc(var(--nav-h) + 14px); right: 14px; border-width: 2px 2px 0 0; }
.hud-bl { bottom: 14px; left: 14px;  border-width: 0 0 2px 2px; }
.hud-br { bottom: 14px; right: 14px; border-width: 0 2px 2px 0; }
.hud-info {
  position: absolute;
  bottom: 28px;
  right: 28px;
  text-align: right;
  display: flex;
  flex-direction: column;
  gap: 5px;
}
.hud-unit {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--accent);
  letter-spacing: 0.16em;
}
.hud-status {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--text-dim);
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 6px;
  letter-spacing: 0.1em;
}
.hud-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
  animation: hud-blink 1.5s ease-in-out infinite;
}
.hud-sync {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  opacity: 0.85;
}
@keyframes hud-blink {
  0%, 100% { opacity: 1; }
  50%       { opacity: 0.2; }
}
@media (max-width: 640px) {
  #eva-canvas, .eva-hud { display: none; }
}
.greeting {
  font-family: var(--font-mono);
  color: var(--accent);
  font-size: 1rem;
  margin-bottom: 1rem;
}
#hero h1 {
  font-size: clamp(2.5rem, 7vw, 5rem);
  font-weight: 800;
  line-height: 1.1;
  color: #e6f1ff;
}
#hero h2 {
  font-size: clamp(1.5rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--text-dim);
  margin-top: 0.3rem;
}
.bio {
  color: var(--text-dim);
  max-width: 540px;
  margin: 1.5rem 0 2.5rem;
  font-size: 1.05rem;
}

/* ── Button ── */
.btn {
  display: inline-block;
  padding: 0.85rem 1.75rem;
  border: 1px solid var(--accent);
  border-radius: 4px;
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.9rem;
  transition: background 0.2s;
}
.btn:hover {
  background: rgba(100, 255, 218, 0.1);
  text-decoration: none;
}

/* ── About ── */
.about-grid {
  display: grid;
  grid-template-columns: 3fr 2fr;
  gap: 3rem;
  align-items: start;
}
.about-text p { color: var(--text-dim); margin-bottom: 1rem; }
.profile-photo {
  width: 100%;
  max-width: 280px;
  border-radius: 4px;
  border: 2px solid var(--accent);
  display: block;
  margin: 0 auto;
  object-fit: cover;
}

/* ── Skills ── */
.skills-groups {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 2rem;
}
.skills-group h4 {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  margin-bottom: 0.75rem;
}
.skills-list {
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.3rem;
}
.skills-list li {
  font-family: var(--font-mono);
  font-size: 0.9rem;
  color: var(--text-dim);
  padding: 0.3rem 0;
}
.skills-list li::before {
  content: '▹ ';
  color: var(--accent);
}

/* ── Timeline (Experience & Education) ── */
.timeline {
  display: flex;
  flex-direction: column;
  gap: 2rem;
}
.timeline-item {
  background: var(--bg-light);
  border-radius: 4px;
  padding: 1.75rem;
  border-left: 2px solid var(--accent);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  flex-wrap: wrap;
}
.timeline-header h4 { font-size: 1.1rem; color: #e6f1ff; }
.timeline-org { color: var(--accent); font-size: 0.9rem; margin-top: 0.2rem; }
.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  white-space: nowrap;
}
.timeline-sub {
  font-size: 0.9rem;
  color: var(--text-dim);
}
.timeline-bullets {
  padding-left: 1.25rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.timeline-bullets li {
  font-size: 0.9rem;
  color: var(--text-dim);
}

/* ── Certifications ── */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1rem;
}
.cert-card {
  background: var(--bg-light);
  border-radius: 4px;
  padding: 1.25rem 1.5rem;
  border-top: 2px solid var(--accent);
}
.cert-name {
  font-size: 0.95rem;
  color: #e6f1ff;
  font-weight: 600;
  margin-bottom: 0.3rem;
}
.cert-issuer {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
}
.cert-date {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
  margin-top: 0.25rem;
}

/* ── Resume ── */
.resume-inner {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
  align-items: flex-start;
}
.resume-embed-wrap {
  width: 100%;
  border: 1px solid rgba(100, 255, 218, 0.15);
  border-radius: 4px;
  overflow: hidden;
}
.resume-embed-wrap iframe {
  display: block;
  border: none;
}

/* ── Projects ── */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 1.25rem;
}
.card {
  background: var(--bg-light);
  border-radius: 4px;
  padding: 1.75rem;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  transition: transform 0.2s;
}
.card:hover { transform: translateY(-4px); }
.card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.folder { font-size: 2rem; }
.card-links a { font-size: 1.25rem; }
.card h4 { font-size: 1.1rem; color: #e6f1ff; }
.card p { font-size: 0.9rem; color: var(--text-dim); flex: 1; }
.tech-list {
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 0.5rem;
}
.tech-list li {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* ── Contact ── */
.contact-inner {
  max-width: 600px;
  margin: 0 auto;
}
.contact-inner > p {
  color: var(--text-dim);
  margin-bottom: 2rem;
  font-size: 1.05rem;
  text-align: center;
}
#contact-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}
.form-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25rem;
}
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}
.form-group label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
}
.form-group input,
.form-group textarea {
  background: var(--bg-light);
  border: 1px solid rgba(100, 255, 218, 0.2);
  border-radius: 4px;
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 0.95rem;
  padding: 0.75rem 1rem;
  outline: none;
  transition: border-color 0.2s;
  resize: vertical;
}
.form-group input:focus,
.form-group textarea:focus {
  border-color: var(--accent);
}
.form-group input::placeholder,
.form-group textarea::placeholder {
  color: var(--text-dim);
  opacity: 0.6;
}
#contact-form .btn {
  align-self: center;
  cursor: pointer;
  background: none;
  font-family: var(--font-mono);
}
#contact-form .btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}
#form-status {
  text-align: center;
  font-family: var(--font-mono);
  font-size: 0.85rem;
  min-height: 1.2em;
}
#form-status.success { color: var(--accent); }
#form-status.error   { color: #ff6b6b; }
@media (max-width: 540px) {
  .form-row { grid-template-columns: 1fr; }
}

/* ── Footer ── */
footer {
  text-align: center;
  padding: 2rem;
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--text-dim);
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}
.social-links { display: flex; justify-content: center; gap: 1.5rem; }
.social-links a { color: var(--text-dim); transition: color 0.2s; }
.social-links a:hover { color: var(--accent); text-decoration: none; }

/* ── Responsive ── */
@media (max-width: 640px) {
  nav ul { gap: 1rem; }
  .about-grid { grid-template-columns: 1fr; }
  .about-img { order: -1; }
}
