/* ================================================
   PORTFOLIO — Jose / Network Engineer
   Design: Light theme — Vercel-style white precision + green accent
   ================================================ */

:root {
  --bg:         #ffffff;
  --bg-alt:     #fafafa;
  --surface:    #ffffff;
  --border:     #e5e5e5;
  --text:       #0a0a0a;
  --text-dim:   #525252;
  --text-mute:  #a3a3a3;
  --accent:     #16a34a;
  --accent-dim: #15803d;
  --radius:     10px;
  --max-w:      1120px;
  --font-sans:  'Geist', system-ui, -apple-system, sans-serif;
  --font-mono:  'Geist Mono', ui-monospace, monospace;
  --shadow-sm:  0 1px 2px rgba(0,0,0,0.04);
  --shadow-md:  0 2px 8px rgba(0,0,0,0.06);
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  font-feature-settings: 'cv11', 'ss01';
}

a { color: inherit; text-decoration: none; }
.container { max-width: var(--max-w); margin: 0 auto; padding: 0 24px; }

/* ---------- NAV ---------- */
.nav {
  position: sticky; top: 0; z-index: 100;
  background: rgba(255,255,255,0.85);
  backdrop-filter: saturate(180%) blur(12px);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  border-bottom: 1px solid var(--border);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 60px;
}
.brand { display: flex; align-items: center; gap: 10px; font-weight: 600; }
.brand-mark {
  width: 28px; height: 28px; border-radius: 6px;
  background: var(--accent); color: #ffffff;
  display: grid; place-items: center; font-weight: 700; font-size: 13px;
}
.brand-name { letter-spacing: -0.02em; }
.dot { color: var(--accent); }
.nav-links { display: flex; gap: 28px; font-size: 14px; color: var(--text-dim); }
.nav-links a { transition: color 0.15s; }
.nav-links a:hover { color: var(--text); }
.nav-cta { color: var(--text) !important; }
.nav-cta:hover { color: var(--accent) !important; }

/* ---------- HERO ---------- */
.hero {
  padding: 80px 0 60px;
  background:
    radial-gradient(circle at 80% 0%, rgba(22, 163, 74, 0.08), transparent 50%),
    radial-gradient(circle at 0% 100%, rgba(22, 163, 74, 0.05), transparent 50%);
}
.hero-grid {
  display: grid; grid-template-columns: 1.3fr 1fr;
  gap: 60px; align-items: center;
}
.status-pill {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 6px 12px; border: 1px solid var(--border);
  border-radius: 999px; font-size: 13px; color: var(--text-dim);
  background: var(--surface); margin-bottom: 28px;
  box-shadow: var(--shadow-sm);
}
.status-dot {
  width: 7px; height: 7px; border-radius: 50%;
  background: var(--accent); box-shadow: 0 0 8px var(--accent);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 50% { opacity: 0.4; } }

.hero-title {
  font-size: clamp(36px, 5vw, 56px);
  font-weight: 600; line-height: 1.1;
  letter-spacing: -0.03em; margin-bottom: 20px;
}
.accent { color: var(--accent); }
.grad {
  background: linear-gradient(120deg, var(--text), var(--accent));
  -webkit-background-clip: text; background-clip: text;
  -webkit-text-fill-color: transparent;
}
.hero-sub {
  font-size: 17px; color: var(--text-dim); max-width: 520px;
  margin-bottom: 32px;
}
.hero-cta { display: flex; gap: 12px; margin-bottom: 40px; }

.btn {
  display: inline-flex; align-items: center; gap: 6px;
  padding: 11px 20px; border-radius: 8px; font-size: 14px;
  font-weight: 500; cursor: pointer; transition: all 0.15s;
  border: 1px solid transparent;
}
.btn-primary { background: var(--text); color: var(--bg); }
.btn-primary:hover { background: var(--accent); color: #ffffff; }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border); }
.btn-ghost:hover { border-color: var(--accent); color: var(--accent); }

.hero-meta {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px; padding-top: 28px; border-top: 1px solid var(--border);
}
.hero-meta .k {
  display: block; font-size: 11px; color: var(--text-mute);
  text-transform: uppercase; letter-spacing: 0.08em; margin-bottom: 4px;
  font-family: var(--font-mono);
}
.hero-meta .v { font-size: 14px; color: var(--text); }

/* ---------- TOPOLOGY SVG ---------- */
.hero-visual { display: flex; justify-content: center; }
.topology { width: 100%; max-width: 380px; height: auto; }
.topology .links { stroke: #16a34a !important; opacity: 0.4; }
.topology .pkt { filter: drop-shadow(0 0 4px var(--accent)); }
@keyframes orbit {
  0%   { offset-distance: 0%;   opacity: 0; }
  10%  { opacity: 1; }
  90%  { opacity: 1; }
  100% { offset-distance: 100%; opacity: 0; }
}
.pkt-1 { offset-path: path("M200,200 L80,80");  animation: orbit 3s linear infinite; }
.pkt-2 { offset-path: path("M200,200 L320,80"); animation: orbit 3s linear infinite 0.75s; }
.pkt-3 { offset-path: path("M200,200 L80,320"); animation: orbit 3s linear infinite 1.5s; }
.pkt-4 { offset-path: path("M200,200 L320,320"); animation: orbit 3s linear infinite 2.25s; }

/* ---------- STATS ---------- */
.stats {
  padding: 48px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border);
  background: var(--bg-alt);
}
.stats-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 32px; text-align: center;
}
.stat-num {
  display: block; font-size: 36px; font-weight: 600;
  color: var(--text); letter-spacing: -0.02em;
  font-family: var(--font-mono);
}
.stat-label {
  font-size: 12px; color: var(--text-mute);
  text-transform: uppercase; letter-spacing: 0.08em; margin-top: 4px;
}

/* ---------- SECTION BASE ---------- */
.section { padding: 100px 0; }
.section-alt { background: var(--bg-alt); }
.section-head { margin-bottom: 56px; }
.section-tag {
  display: inline-block; font-family: var(--font-mono);
  font-size: 12px; color: var(--accent); margin-bottom: 12px;
  letter-spacing: 0.04em;
}
.section-head h2 {
  font-size: clamp(28px, 3.5vw, 40px); font-weight: 600;
  letter-spacing: -0.025em; max-width: 700px;
}

/* ---------- TIMELINE / ROLES ---------- */
.timeline { display: flex; flex-direction: column; gap: 32px; }
.role {
  padding: 28px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--shadow-sm);
}
.role:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}
.role-head {
  display: flex; justify-content: space-between; align-items: start;
  margin-bottom: 16px; gap: 16px;
}
.role h3 { font-size: 20px; font-weight: 600; margin-bottom: 4px; }
.role-co { font-size: 14px; color: var(--text-dim); }
.role-period {
  font-family: var(--font-mono); font-size: 12px; color: var(--text-mute);
  white-space: nowrap;
}
.highlights {
  list-style: none; margin: 16px 0; padding-left: 0;
}
.highlights li {
  position: relative; padding-left: 20px; margin-bottom: 8px;
  font-size: 15px; color: var(--text-dim);
}
.highlights li::before {
  content: '→'; position: absolute; left: 0; color: var(--accent);
  font-family: var(--font-mono); font-size: 13px;
}
.role-stack { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 16px; }
.role-stack span {
  font-family: var(--font-mono); font-size: 11px;
  padding: 4px 10px; border: 1px solid var(--border);
  border-radius: 4px; color: var(--text-dim);
  background: var(--bg-alt);
}

/* ---------- PROJECTS ---------- */
.project-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 20px;
}
.project {
  padding: 24px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface);
  transition: all 0.2s;
  box-shadow: var(--shadow-sm);
}
.project:hover {
  border-color: var(--accent); transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}
.project-head {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 16px; font-family: var(--font-mono); font-size: 12px;
}
.project-year { color: var(--text-mute); }
.project-impact { color: var(--accent); }
.project h3 { font-size: 18px; font-weight: 600; margin-bottom: 10px; }
.project p { font-size: 14px; color: var(--text-dim); margin-bottom: 16px; }
.project-tags { display: flex; flex-wrap: wrap; gap: 6px; }
.project-tags span {
  font-family: var(--font-mono); font-size: 11px;
  padding: 3px 8px; background: rgba(22, 163, 74, 0.08);
  color: var(--accent); border-radius: 4px;
  border: 1px solid rgba(22, 163, 74, 0.2);
}

/* ---------- SKILLS ---------- */
.skills-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 24px;
}
.skill-cat {
  padding: 24px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.skill-cat h4 {
  font-size: 14px; font-weight: 500; color: var(--accent);
  margin-bottom: 16px; font-family: var(--font-mono);
  text-transform: uppercase; letter-spacing: 0.04em;
}
.skill-items { display: flex; flex-wrap: wrap; gap: 8px; }
.skill-items span {
  font-size: 13px; padding: 6px 12px;
  background: var(--bg-alt); border: 1px solid var(--border);
  border-radius: 6px; color: var(--text);
}

/* ---------- CERTS ---------- */
.certs-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 16px;
}
.cert {
  display: grid; grid-template-columns: 60px 1fr auto;
  align-items: center; gap: 16px;
  padding: 20px 24px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--surface);
  transition: border-color 0.2s, box-shadow 0.2s;
  box-shadow: var(--shadow-sm);
}
.cert:hover {
  border-color: var(--accent);
  box-shadow: var(--shadow-md);
}
.cert-year {
  font-family: var(--font-mono); font-size: 22px;
  color: var(--accent); font-weight: 600;
}
.cert-body h4 { font-size: 16px; font-weight: 600; margin-bottom: 2px; }
.cert-body p { font-size: 13px; color: var(--text-dim); }
.cert-tier {
  font-family: var(--font-mono); font-size: 11px;
  padding: 4px 10px; background: var(--bg-alt);
  border: 1px solid var(--border); border-radius: 4px;
  color: var(--text-dim); white-space: nowrap;
}

/* ---------- CONTACT ---------- */
.contact { padding-bottom: 120px; }
.contact-card {
  padding: 56px; border: 1px solid var(--border);
  border-radius: 16px; background: var(--surface);
  box-shadow: var(--shadow-md);
}
.contact-card h2 { font-size: clamp(28px, 3vw, 38px); margin-bottom: 12px; letter-spacing: -0.025em; }
.contact-card > p { color: var(--text-dim); margin-bottom: 32px; max-width: 540px; }

.contact-channels {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 12px;
}
.channel {
  display: flex; flex-direction: column;
  padding: 16px 20px; border: 1px solid var(--border);
  border-radius: var(--radius); background: var(--bg-alt);
  transition: all 0.15s;
}
.channel:hover {
  border-color: var(--accent); background: var(--surface);
  box-shadow: var(--shadow-sm);
}
.ch-label {
  font-family: var(--font-mono); font-size: 11px;
  color: var(--text-mute); text-transform: uppercase;
  letter-spacing: 0.08em; margin-bottom: 4px;
}
.ch-val { font-size: 14px; color: var(--text); }

/* ---------- FOOTER ---------- */
.footer {
  border-top: 1px solid var(--border);
  padding: 28px 0;
  font-family: var(--font-mono); font-size: 12px; color: var(--text-mute);
  background: var(--bg-alt);
}
.footer-inner {
  display: flex; justify-content: space-between; align-items: center;
}
.footer-status { display: flex; align-items: center; gap: 8px; }
.footer-status .status-dot { box-shadow: 0 0 6px var(--accent); }

/* ---------- REVEAL ANIMATION ---------- */
.reveal { opacity: 0; transform: translateY(20px); transition: opacity 0.6s ease, transform 0.6s ease; }
.reveal.is-visible { opacity: 1; transform: translateY(0); }

/* ---------- RESPONSIVE ---------- */
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 40px; }
  .hero-visual { order: -1; max-width: 280px; margin: 0 auto; }
  .nav-links { display: none; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); gap: 24px; }
  .hero-meta { grid-template-columns: 1fr; gap: 16px; }
  .role-head { flex-direction: column; }
  .contact-card { padding: 32px 24px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    transition-duration: 0.01ms !important;
  }
  .reveal { opacity: 1; transform: none; }
}
