/* ============================================================
   DUSTIN ALLARD — dacomputing.net
   Simple, maintainable stylesheet. No framework dependencies.
   ============================================================ */

/* ── TOKENS ── */
:root {
  --bg:          #0d1117;
  --surface:     #161b22;
  --surface-2:   #21262d;
  --border:      #30363d;
  --accent:      #4493f8;
  --accent-dim:  rgba(68, 147, 248, 0.14);
  --accent-ring: rgba(68, 147, 248, 0.3);
  --green:       #3fb950;
  --green-dim:   rgba(63, 185, 80, 0.12);
  --green-ring:  rgba(63, 185, 80, 0.3);
  --amber:       #e6a817;
  --amber-dim:   rgba(230, 168, 23, 0.11);
  --amber-ring:  rgba(230, 168, 23, 0.35);
  --text:        #e6edf3;
  --text-muted:  #8d96a0;
  --text-dim:    #6e7681;
  --heading:     #f0f6fc;

  --font-sans:    'Inter', system-ui, -apple-system, sans-serif;
  --font-display: 'Syne', system-ui, sans-serif;
  --font-mono:    'JetBrains Mono', 'Fira Code', 'Cascadia Code', monospace;

  --radius:    8px;
  --radius-lg: 12px;
  --max-w:     1080px;
  --nav-h:     60px;
}

/* ── RESET ── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; scroll-padding-top: var(--nav-h); }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.7;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
}
img { max-width: 100%; display: block; }
a { color: var(--accent); text-decoration: none; transition: opacity 0.15s; }
a:hover { opacity: 0.8; }
ul { list-style: none; }

/* ── LAYOUT ── */
.container {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
}
section { padding: 80px 0; }
.section-alt { background: var(--surface); }

/* ── SECTION TITLE ── */
.section-title {
  font-family: var(--font-display);
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--heading);
  margin-bottom: 48px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--accent);
  display: inline-block;
  letter-spacing: -0.01em;
}

/* ── SCROLL REVEAL ── */
.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.55s ease, transform 0.55s ease;
}
.reveal.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ── TAGS ── */
.tags { display: flex; flex-wrap: wrap; gap: 7px; }
.tag {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-muted);
  padding: 3px 9px;
  border-radius: 4px;
}
.tag.accent {
  background: var(--accent-dim);
  border-color: var(--accent-ring);
  color: var(--accent);
}

/* ============================================================
   NAVIGATION
   ============================================================ */
#nav {
  position: fixed;
  top: 0; left: 0; right: 0;
  z-index: 100;
  height: var(--nav-h);
  background: rgba(13, 17, 23, 0.8);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
  transition: border-color 0.3s, background 0.3s;
}
#nav.scrolled {
  border-bottom-color: var(--border);
  background: rgba(13, 17, 23, 0.96);
}

.nav-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 24px;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.nav-brand {
  font-family: var(--font-mono);
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--accent);
  letter-spacing: 0.06em;
}
.nav-brand:hover { opacity: 1; }

.nav-links {
  display: flex;
  align-items: center;
  gap: 4px;
}
.nav-links a {
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--text-muted);
  padding: 5px 12px;
  border-radius: var(--radius);
  transition: color 0.15s, background 0.15s;
}
.nav-links a:hover {
  color: var(--text);
  background: var(--surface-2);
  opacity: 1;
}
.nav-links .nav-cta {
  background: var(--accent);
  color: #fff;
  margin-left: 8px;
}
.nav-links .nav-cta:hover { background: var(--accent); opacity: 0.88; }

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 5px;
  background: none;
  border: none;
  cursor: pointer;
  padding: 6px;
}
.nav-toggle span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text);
  border-radius: 2px;
  transition: 0.25s;
}

/* ============================================================
   HERO
   ============================================================ */
#hero {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: calc(var(--nav-h) + 60px) 24px 80px;
  position: relative;
  overflow: hidden;
  background:
    radial-gradient(ellipse at 12% 65%, rgba(68, 147, 248, 0.13) 0%, transparent 52%),
    radial-gradient(ellipse at 88% 18%, rgba(63, 185, 80, 0.07) 0%, transparent 45%),
    var(--bg);
}

/* Subtle dot-grid overlay */
#hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background-image: radial-gradient(circle, rgba(68, 147, 248, 0.18) 1px, transparent 1px);
  background-size: 34px 34px;
  mask-image: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.6) 100%);
  -webkit-mask-image: radial-gradient(ellipse at center, transparent 40%, rgba(0,0,0,0.6) 100%);
  pointer-events: none;
  z-index: 0;
}

.hero-inner {
  max-width: var(--max-w);
  margin: 0 auto;
  width: 100%;
  position: relative;
  z-index: 1;
}

.hero-label {
  font-family: var(--font-mono);
  font-size: 0.8rem;
  color: var(--accent);
  letter-spacing: 0.1em;
  text-transform: uppercase;
  margin-bottom: 18px;
}

.hero-name {
  font-family: var(--font-display);
  font-size: clamp(2.8rem, 7vw, 5rem);
  font-weight: 800;
  color: var(--heading);
  letter-spacing: -0.03em;
  line-height: 1.03;
  margin-bottom: 22px;
}

.hero-tagline {
  font-size: 1.1rem;
  color: var(--text-muted);
  line-height: 1.75;
  max-width: 560px;
  margin-bottom: 22px;
}

/* Credential signal line */
.hero-credential {
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--green);
  letter-spacing: 0.05em;
  margin-bottom: 30px;
}
.cred-dot {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--green);
  flex-shrink: 0;
  animation: pulse-green 2.4s ease-in-out infinite;
}
@keyframes pulse-green {
  0%, 100% { box-shadow: 0 0 0 0 rgba(63, 185, 80, 0.5); }
  50%       { box-shadow: 0 0 0 6px rgba(63, 185, 80, 0); }
}

.hero-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 36px;
}
.badge {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  background: var(--surface-2);
  border: 1px solid var(--border);
  color: var(--text-dim);
  padding: 4px 13px;
  border-radius: 20px;
  letter-spacing: 0.03em;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: 10px; }

.btn {
  display: inline-flex;
  align-items: center;
  padding: 10px 22px;
  border-radius: var(--radius);
  font-size: 0.9rem;
  font-weight: 600;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, opacity 0.15s, box-shadow 0.15s;
  text-decoration: none;
}
.btn:hover { transform: translateY(-2px); opacity: 1; }

.btn-primary {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 0 rgba(68, 147, 248, 0);
}
.btn-primary:hover {
  opacity: 0.92;
  box-shadow: 0 4px 20px rgba(68, 147, 248, 0.3);
}

.btn-secondary {
  background: var(--surface-2);
  color: var(--text);
  border: 1px solid var(--border);
}
.btn-secondary:hover { border-color: var(--accent); color: var(--accent); }

.hero-scroll {
  position: absolute;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%);
  color: var(--text-dim);
  font-size: 1.1rem;
  z-index: 1;
  animation: bob 2.2s ease-in-out infinite;
}
@keyframes bob {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50%       { transform: translateX(-50%) translateY(7px); }
}

/* ============================================================
   ABOUT
   ============================================================ */
.about-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 56px;
  align-items: start;
}

.about-text p {
  color: var(--text-muted);
  font-size: 1rem;
  line-height: 1.8;
  margin-bottom: 16px;
}
.about-text p:last-child { margin-bottom: 0; }

.about-stats {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
.stat {
  display: flex;
  flex-direction: column;
  gap: 5px;
  padding: 18px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-align: center;
  transition: border-color 0.2s;
}
.stat:hover { border-color: var(--accent-ring); }
.stat-num {
  font-family: var(--font-display);
  font-size: 1.9rem;
  font-weight: 800;
  color: var(--accent);
  line-height: 1;
  letter-spacing: -0.02em;
}
.stat-lbl {
  font-size: 0.72rem;
  color: var(--text-dim);
  text-transform: uppercase;
  letter-spacing: 0.07em;
  line-height: 1.4;
}

/* ============================================================
   WHAT I DELIVER
   ============================================================ */
.delivers-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.deliver-card {
  padding: 28px 24px;
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  background: var(--surface-2);
  position: relative;
  transition: border-color 0.2s, transform 0.2s;
}
.deliver-card:hover { transform: translateY(-2px); }

.deliver-card:nth-child(1) { border-top: 3px solid var(--accent); }
.deliver-card:nth-child(1):hover { border-color: var(--accent); border-top-color: var(--accent); }

.deliver-card:nth-child(2) { border-top: 3px solid var(--amber); }
.deliver-card:nth-child(2):hover { border-color: var(--amber); border-top-color: var(--amber); }

.deliver-card:nth-child(3) { border-top: 3px solid var(--green); }
.deliver-card:nth-child(3):hover { border-color: var(--green); border-top-color: var(--green); }

.deliver-num {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  color: var(--text-dim);
  letter-spacing: 0.12em;
  margin-bottom: 14px;
}
.deliver-card h3 {
  font-family: var(--font-display);
  font-size: 1rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 10px;
  line-height: 1.3;
  letter-spacing: -0.01em;
}
.deliver-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.7;
}

/* ============================================================
   SKILLS
   ============================================================ */
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 20px;
}
.skill-card {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
}
.skill-card h3 {
  font-size: 0.78rem;
  font-weight: 600;
  color: var(--accent);
  text-transform: uppercase;
  letter-spacing: 0.09em;
  margin-bottom: 14px;
}

/* ============================================================
   EXPERIENCE / TIMELINE
   ============================================================ */
.timeline { display: flex; flex-direction: column; }

.timeline-item {
  position: relative;
  padding: 0 0 40px 28px;
  border-left: 2px solid var(--border);
}
.timeline-item:last-child { padding-bottom: 0; }

.timeline-item::before {
  content: '';
  position: absolute;
  left: -7px;
  top: 10px;
  width: 12px;
  height: 12px;
  background: var(--accent);
  border-radius: 50%;
  border: 2px solid var(--bg);
  transition: transform 0.2s, box-shadow 0.2s;
}
.timeline-item:hover::before {
  transform: scale(1.25);
  box-shadow: 0 0 0 3px var(--accent-ring);
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 14px;
}
.timeline-role {
  font-family: var(--font-display);
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--heading);
  margin-bottom: 3px;
  letter-spacing: -0.01em;
}
.timeline-company {
  font-size: 0.875rem;
  color: var(--text-muted);
}
.timeline-date {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--text-dim);
  white-space: nowrap;
  padding-top: 3px;
  flex-shrink: 0;
}

.timeline-bullets {
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.timeline-bullets li {
  font-size: 0.9rem;
  color: var(--text-muted);
  padding-left: 18px;
  position: relative;
  line-height: 1.65;
}
.timeline-bullets li::before {
  content: '→';
  position: absolute;
  left: 0;
  color: var(--accent);
  font-size: 0.85em;
  top: 1px;
}

/* ============================================================
   PROJECTS
   ============================================================ */
.projects-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(310px, 1fr));
  gap: 18px;
}
.project-card {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px;
  display: flex;
  flex-direction: column;
  gap: 12px;
  transition: border-color 0.2s, transform 0.2s;
}
.project-card:hover { border-color: var(--accent); transform: translateY(-2px); }

/* Featured project — APT incident card */
.project-card.featured {
  grid-column: 1 / -1;
  border-color: var(--amber-ring);
  background: linear-gradient(135deg, var(--surface-2), var(--amber-dim));
  border-width: 1px;
  border-top: 2px solid var(--amber);
}
.project-card.featured:hover {
  border-color: var(--amber);
  border-top-color: var(--amber);
  transform: translateY(-2px);
}

.featured-label {
  font-family: var(--font-mono);
  font-size: 0.65rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--amber);
  border: 1px solid var(--amber-ring);
  background: var(--amber-dim);
  padding: 3px 9px;
  border-radius: 3px;
  display: inline-block;
  align-self: flex-start;
}

.project-badge {
  font-family: var(--font-mono);
  font-size: 0.73rem;
  color: var(--amber);
  white-space: nowrap;
  flex-shrink: 0;
  letter-spacing: 0.04em;
}

.project-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 10px;
}
.project-header h3 {
  font-size: 0.975rem;
  font-weight: 600;
  color: var(--heading);
  line-height: 1.35;
}
.project-link {
  font-family: var(--font-mono);
  font-size: 0.78rem;
  color: var(--accent);
  white-space: nowrap;
  flex-shrink: 0;
}

.project-card p {
  font-size: 0.875rem;
  color: var(--text-muted);
  line-height: 1.65;
  flex: 1;
}

/* ============================================================
   CERTIFICATIONS
   ============================================================ */
.certs-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
  margin-bottom: 14px;
}
.cert-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 10px;
  padding: 22px 14px;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  text-align: center;
  color: var(--text-muted);
  transition: border-color 0.2s, color 0.2s, transform 0.2s;
}
.cert-card:hover {
  border-color: var(--green);
  color: var(--green);
  transform: translateY(-2px);
  opacity: 1;
}
.cert-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: var(--green-dim);
  border: 1px solid var(--green-ring);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--green);
  font-size: 1rem;
  transition: background 0.2s;
}
.cert-card:hover .cert-icon { background: rgba(63, 185, 80, 0.22); }
.cert-name {
  font-size: 0.8rem;
  font-weight: 500;
  line-height: 1.4;
}
.certs-note {
  font-size: 0.78rem;
  color: var(--text-dim);
  text-align: center;
}

/* ============================================================
   FOOTER
   ============================================================ */
footer {
  background: var(--surface);
  border-top: 1px solid var(--border);
  padding: 36px 0;
  text-align: center;
}
.footer-links {
  display: flex;
  justify-content: center;
  gap: 28px;
  margin-bottom: 12px;
}
.footer-links a {
  font-size: 0.875rem;
  color: var(--text-muted);
}
.footer-links a:hover { color: var(--accent); opacity: 1; }
.footer-copy {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  color: var(--text-dim);
}

/* ============================================================
   RESPONSIVE
   ============================================================ */
@media (max-width: 860px) {
  .about-grid {
    grid-template-columns: 1fr;
    gap: 40px;
  }
  .about-stats {
    grid-template-columns: repeat(4, 1fr);
  }
  .delivers-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }
}

@media (max-width: 640px) {
  section { padding: 60px 0; }

  .nav-toggle { display: flex; }
  .nav-links {
    display: none;
    position: absolute;
    top: var(--nav-h);
    left: 0;
    right: 0;
    background: var(--surface);
    border-bottom: 1px solid var(--border);
    flex-direction: column;
    padding: 12px;
    gap: 2px;
  }
  .nav-links.open { display: flex; }
  .nav-links a {
    width: 100%;
    text-align: center;
    padding: 9px;
  }
  .nav-links .nav-cta { margin-left: 0; margin-top: 6px; }

  .about-stats { grid-template-columns: repeat(2, 1fr); }
  .timeline-header { flex-direction: column; gap: 4px; }
  .hero-label { font-size: 0.7rem; }
  .hero-credential { font-size: 0.7rem; }
}

@media (max-width: 420px) {
  .hero-badges { flex-direction: column; }
}
