/* ============================================================
   style.css — Samuel Howard Portfolio
   ============================================================ */

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #f5f5f7;
  --bg-card: #ffffff;
  --bg-dark: #1d1d1f;
  --text-primary: #1d1d1f;
  --text-secondary: #6e6e73;
  --text-tertiary: #86868b;
  --accent: #0071e3;
  --accent-hover: #0077ed;
  --border: rgba(0,0,0,0.08);
  --shadow-sm: 0 2px 8px rgba(0,0,0,0.06);
  --shadow-md: 0 8px 30px rgba(0,0,0,0.10);
  --shadow-lg: 0 20px 60px rgba(0,0,0,0.12);
  --radius: 18px;
  --radius-sm: 10px;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, sans-serif;
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

/* ── NAV ── */
nav {
  position: fixed; top: 0; left: 0; right: 0; z-index: 100;
  background: rgba(245,245,247,0.80);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
  border-bottom: 1px solid var(--border);
  height: 52px;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 5%;
  transition: background 0.3s;
}
.nav-logo {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 1.1rem;
  letter-spacing: -0.01em;
  color: var(--text-primary);
  text-decoration: none;
}
.nav-links { display: flex; gap: 2rem; list-style: none; }
.nav-links a {
  font-size: 0.82rem; font-weight: 400; color: var(--text-secondary);
  text-decoration: none; letter-spacing: 0.01em;
  transition: color 0.2s;
}
.nav-links a:hover { color: var(--text-primary); }

/* ── HERO ── */
.hero {
  min-height: 100vh;
  display: flex; flex-direction: column;
  align-items: center; justify-content: center;
  text-align: center;
  padding: 120px 5% 80px;
  position: relative;
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background: radial-gradient(ellipse 80% 60% at 50% 0%, rgba(0,113,227,0.08) 0%, transparent 70%);
  pointer-events: none;
}
.hero-eyebrow {
  display: inline-block;
  font-size: 0.78rem; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 1.5rem;
  opacity: 0; animation: fadeUp 0.8s 0.2s ease forwards;
}
.hero-name {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(3.5rem, 8vw, 7rem);
  font-weight: 400; line-height: 1.0;
  letter-spacing: -0.03em;
  color: var(--text-primary);
  margin-bottom: 1.5rem;
  opacity: 0; animation: fadeUp 0.8s 0.35s ease forwards;
}
.hero-name em { font-style: italic; color: var(--accent); }
.hero-tagline {
  max-width: 520px;
  font-size: 1.15rem; font-weight: 300;
  color: var(--text-secondary);
  line-height: 1.7;
  margin-bottom: 2.5rem;
  opacity: 0; animation: fadeUp 0.8s 0.5s ease forwards;
}
.hero-cta {
  display: flex; gap: 0.75rem; flex-wrap: wrap; justify-content: center;
  opacity: 0; animation: fadeUp 0.8s 0.65s ease forwards;
}

/* ── BUTTONS ── */
.btn {
  display: inline-block; padding: 0.75rem 1.75rem;
  border-radius: 980px; font-size: 0.88rem; font-weight: 500;
  text-decoration: none; transition: all 0.2s; cursor: pointer; border: none;
}
.btn-primary { background: var(--accent); color: #fff; }
.btn-primary:hover { background: var(--accent-hover); transform: scale(1.02); }
.btn-secondary {
  background: transparent; color: var(--accent);
  border: 1.5px solid var(--accent);
}
.btn-secondary:hover { background: rgba(0,113,227,0.06); }

/* ── SECTION BASE ── */
section { padding: 100px 5%; }
.section-label {
  font-size: 0.75rem; font-weight: 500; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--accent);
  margin-bottom: 0.75rem;
}
.section-title {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 400; line-height: 1.1;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  margin-bottom: 1rem;
}
.section-sub {
  font-size: 1.05rem; color: var(--text-secondary);
  font-weight: 300; max-width: 480px; line-height: 1.7;
  margin-bottom: 3rem;
}
.container { max-width: 1080px; margin: 0 auto; }

/* ── ABOUT ── */
#about { background: var(--bg-dark); color: #f5f5f7; }
#about .section-title { color: #f5f5f7; }
#about .section-sub { color: #86868b; }
.about-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 4rem; align-items: start;
}
.about-body { font-size: 1.05rem; font-weight: 300; color: #d1d1d6; line-height: 1.85; }
.about-body p + p { margin-top: 1.25rem; }
.about-stats { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.stat-card {
  background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: background 0.2s;
}
.stat-card:hover { background: rgba(255,255,255,0.09); }
.stat-num {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 2.4rem; color: #f5f5f7;
  letter-spacing: -0.03em; line-height: 1;
  margin-bottom: 0.3rem;
}
.stat-num span { font-size: 1.4rem; color: var(--accent); }
.stat-desc { font-size: 0.82rem; color: #86868b; font-weight: 400; }

/* ── SKILLS ── */
#skills { background: var(--bg); }
.skills-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 1.25rem;
}
.skill-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.25s, transform 0.25s;
}
.skill-card:hover { box-shadow: var(--shadow-md); transform: translateY(-3px); }
.skill-icon {
  width: 44px; height: 44px; border-radius: 12px;
  background: linear-gradient(135deg, var(--accent) 0%, #34aadc 100%);
  display: flex; align-items: center; justify-content: center;
  margin-bottom: 1.25rem; font-size: 1.25rem;
}
.skill-card h3 { font-size: 1rem; font-weight: 600; margin-bottom: 0.5rem; }
.skill-card p { font-size: 0.875rem; color: var(--text-secondary); line-height: 1.65; }
.tag-row { display: flex; flex-wrap: wrap; gap: 0.4rem; margin-top: 1rem; }
.tag {
  font-size: 0.72rem; font-weight: 500; letter-spacing: 0.03em;
  padding: 0.25rem 0.65rem; border-radius: 980px;
  background: rgba(0,113,227,0.08); color: var(--accent);
}

/* ── EXPERIENCE ── */
#experience { background: var(--bg); border-top: 1px solid var(--border); }
.timeline { position: relative; padding-left: 2rem; }
.timeline::before {
  content: '';
  position: absolute; left: 0; top: 8px; bottom: 0;
  width: 1.5px; background: var(--border);
}
.timeline-item {
  position: relative; margin-bottom: 3rem;
  opacity: 0; transform: translateY(20px);
  transition: opacity 0.6s ease, transform 0.6s ease;
}
.timeline-item.visible { opacity: 1; transform: none; }
.timeline-dot {
  position: absolute; left: -2.45rem; top: 6px;
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--accent); border: 2px solid var(--bg);
  box-shadow: 0 0 0 3px rgba(0,113,227,0.2);
}
.timeline-date {
  font-size: 0.75rem; color: var(--text-tertiary);
  font-weight: 500; letter-spacing: 0.05em;
  text-transform: uppercase; margin-bottom: 0.4rem;
}
.timeline-role { font-size: 1.05rem; font-weight: 600; color: var(--text-primary); margin-bottom: 0.15rem; }
.timeline-company { font-size: 0.9rem; color: var(--accent); margin-bottom: 0.85rem; }
.timeline-bullets { list-style: none; }
.timeline-bullets li {
  font-size: 0.88rem; color: var(--text-secondary);
  padding: 0.3rem 0; padding-left: 1rem; position: relative; line-height: 1.6;
}
.timeline-bullets li::before {
  content: '—';
  position: absolute; left: 0; color: var(--accent); font-size: 0.75rem;
}

/* ── PROJECT ── */
#project { background: var(--bg-dark); }
#project .section-label { color: #86868b; }
#project .section-title { color: #f5f5f7; }
#project .section-sub { color: #86868b; }
.project-card {
  background: rgba(255,255,255,0.05);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: var(--radius);
  overflow: hidden;
}
.project-poster {
  width: 100%; aspect-ratio: 16/9; object-fit: cover;
  display: block; cursor: pointer;
  transition: opacity 0.2s;
}
.project-poster:hover { opacity: 0.9; }
.project-body { padding: 2.5rem; }
.project-body h3 {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 1.7rem; color: #f5f5f7;
  margin-bottom: 0.5rem; font-weight: 400;
}
.project-body .sub {
  font-size: 0.82rem; color: #86868b;
  letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 1rem;
}
.project-body p { font-size: 0.92rem; color: #d1d1d6; line-height: 1.75; margin-bottom: 1rem; }
.project-chips { display: flex; flex-wrap: wrap; gap: 0.5rem; margin-top: 1.25rem; }
.chip {
  font-size: 0.72rem; font-weight: 500; padding: 0.3rem 0.8rem;
  border-radius: 980px; border: 1px solid rgba(255,255,255,0.14);
  color: #d1d1d6; letter-spacing: 0.03em;
}

/* ── CONTACT ── */
#contact { background: var(--bg); text-align: center; }
.contact-card {
  max-width: 560px; margin: 0 auto;
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: 24px;
  padding: 3.5rem 2.5rem;
  box-shadow: var(--shadow-md);
}
.contact-card h2 {
  font-family: 'DM Serif Display', Georgia, serif;
  font-size: 2rem; font-weight: 400;
  margin-bottom: 0.75rem;
  letter-spacing: -0.02em;
}
.contact-card p { color: var(--text-secondary); font-size: 0.95rem; margin-bottom: 2rem; line-height: 1.7; }
.contact-links { display: flex; flex-direction: column; gap: 0.75rem; }
.contact-link {
  display: flex; align-items: center; justify-content: space-between;
  padding: 1rem 1.25rem;
  background: var(--bg);
  border-radius: var(--radius-sm);
  text-decoration: none;
  color: var(--text-primary);
  font-size: 0.9rem; font-weight: 500;
  transition: background 0.2s;
}
.contact-link:hover { background: rgba(0,113,227,0.07); color: var(--accent); }
.contact-link-label { display: flex; align-items: center; gap: 0.6rem; }
.arrow { color: var(--text-tertiary); font-size: 0.85rem; }

/* ── FOOTER ── */
footer {
  text-align: center; padding: 2rem 5%;
  border-top: 1px solid var(--border);
  font-size: 0.78rem; color: var(--text-tertiary);
}

/* ── ANIMATIONS ── */
@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to   { opacity: 1; transform: translateY(0); }
}
.reveal {
  opacity: 0; transform: translateY(28px);
  transition: opacity 0.7s ease, transform 0.7s ease;
}
.reveal.visible { opacity: 1; transform: none; }

/* ── MODAL ── */
.modal-overlay {
  display: none; position: fixed; inset: 0; z-index: 200;
  background: rgba(0,0,0,0.75); backdrop-filter: blur(6px);
  align-items: center; justify-content: center;
}
.modal-overlay.open { display: flex; }
.modal-inner {
  background: #1d1d1f; border-radius: var(--radius);
  max-width: 90vw; max-height: 88vh;
  overflow-y: auto; padding: 2rem;
  position: relative;
}
.modal-inner img { width: 100%; border-radius: var(--radius-sm); }
.modal-close {
  position: absolute; top: 1rem; right: 1rem;
  background: rgba(255,255,255,0.12); border: none; border-radius: 50%;
  width: 36px; height: 36px; font-size: 1.1rem; color: #fff; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: background 0.2s;
}
.modal-close:hover { background: rgba(255,255,255,0.2); }

/* ── RESPONSIVE ── */
@media (max-width: 760px) {
  .about-grid { grid-template-columns: 1fr; gap: 2.5rem; }
  .nav-links { display: none; }
  .hero-name { font-size: clamp(2.8rem, 12vw, 4.5rem); }
  .project-body { padding: 1.5rem; }
  .contact-card { padding: 2.5rem 1.5rem; }
}