/*
  Professional portfolio stylesheet
  Suggested sections/classes:
  .site-header, .nav, .hero, .section, .about-grid, .card-grid,
  .project-card, .skill-list, .timeline, .contact-card, .site-footer
*/

@import url('https://fonts.googleapis.com/css2?family=DM+Sans:wght@400;500;600;700&family=Manrope:wght@400;500;600;700;800&display=swap');

:root {
  --ink: #172338;
  --muted: #627087;
  --navy: #101d32;
  --navy-light: #1b2d49;
  --blue: #2864dc;
  --blue-dark: #1d4fb4;
  --teal: #19a7a0;
  --surface: #ffffff;
  --surface-soft: #f3f6fb;
  --border: #e1e7f0;
  --shadow: 0 14px 38px rgba(16, 29, 50, 0.09);
  --radius: 18px;
  --content-width: 1120px;
}

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

html { scroll-behavior: smooth; scroll-padding-top: 88px; }

body {
  margin: 0;
  color: var(--ink);
  background: var(--surface);
  font-family: 'DM Sans', sans-serif;
  font-size: 16px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

img { display: block; max-width: 100%; }
a { color: var(--blue); text-decoration: none; }
a:hover { color: var(--blue-dark); }
button, input, textarea { font: inherit; }

h1, h2, h3, h4 {
  margin: 0 0 0.7em;
  color: var(--navy);
  font-family: 'Manrope', sans-serif;
  line-height: 1.2;
}

h1 { font-size: clamp(2.5rem, 6vw, 4.7rem); letter-spacing: -0.055em; }
h2 { font-size: clamp(1.9rem, 4vw, 2.7rem); letter-spacing: -0.04em; }
h3 { font-size: 1.2rem; letter-spacing: -0.02em; }
p { margin: 0 0 1rem; }

.container {
  width: min(var(--content-width), calc(100% - 3rem));
  margin-inline: auto;
}

/* Header and navigation */
.site-header {
  position: sticky;
  z-index: 20;
  top: 0;
  background: rgba(255, 255, 255, 0.92);
  border-bottom: 1px solid rgba(225, 231, 240, 0.85);
  backdrop-filter: blur(14px);
}

.nav {
  min-height: 76px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
}

.logo {
  color: var(--navy);
  font-family: 'Manrope', sans-serif;
  font-size: 1.15rem;
  font-weight: 800;
  letter-spacing: -0.04em;
}
.logo span { color: var(--blue); }

.nav-links { display: flex; align-items: center; gap: 1.7rem; }
.nav-links a {
  color: var(--muted);
  font-size: 0.92rem;
  font-weight: 600;
  transition: color 160ms ease;
}
.nav-links a:hover, .nav-links a.active { color: var(--blue); }

/* Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(5rem, 10vw, 8.5rem) 0;
  color: #fff;
  background:
    radial-gradient(circle at 85% 18%, rgba(25, 167, 160, 0.28), transparent 28%),
    radial-gradient(circle at 8% 100%, rgba(40, 100, 220, 0.28), transparent 35%),
    linear-gradient(120deg, var(--navy), #172b49 65%, #1a3854);
}

.hero::after {
  position: absolute;
  right: -110px;
  bottom: -220px;
  width: 480px;
  height: 480px;
  border: 1px solid rgba(255,255,255,0.12);
  border-radius: 50%;
  content: '';
  box-shadow: 0 0 0 45px rgba(255,255,255,0.025), 0 0 0 90px rgba(255,255,255,0.02);
  pointer-events: none;
}

.hero-layout {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.5fr) minmax(230px, 0.7fr);
  align-items: center;
  gap: clamp(2rem, 6vw, 5rem);
}
.hero-content { position: relative; z-index: 1; max-width: 790px; }

.profile-photo-wrap { display: flex; justify-content: center; align-items: center; }
.profile-photo {
  display: block;
  width: clamp(210px, 26vw, 310px);
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center;
  border: 6px solid rgba(255, 255, 255, 0.88);
  border-radius: 50%;
  background: #dce6f4;
  box-shadow: 0 18px 48px rgba(0, 0, 0, 0.28), 0 0 0 12px rgba(255, 255, 255, 0.08);
}
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  margin-bottom: 1.2rem;
  color: #9fe8df;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}
.eyebrow::before { width: 25px; height: 2px; background: var(--teal); content: ''; }
.hero h1 { max-width: 850px; color: #fff; }
.hero h1 span { color: #83d9d0; }
.hero p { max-width: 660px; color: #d0d9e7; font-size: clamp(1.05rem, 2vw, 1.2rem); }
.hero-actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2rem; }

/* Buttons */
.btn {
  display: inline-flex;
  min-height: 48px;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.25rem;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-weight: 700;
  transition: transform 160ms ease, background 160ms ease, box-shadow 160ms ease;
}
.btn:hover { transform: translateY(-2px); background: var(--blue-dark); color: #fff; box-shadow: 0 8px 20px rgba(40,100,220,0.22); }
.btn-outline { border-color: rgba(255,255,255,0.45); background: transparent; color: #fff; }
.btn-outline:hover { border-color: #fff; background: rgba(255,255,255,0.1); }
.btn-light { background: #fff; color: var(--navy); }
.btn-light:hover { background: #eaf0fb; color: var(--navy); }

/* General sections */
.section { padding: clamp(4rem, 8vw, 6.5rem) 0; }
.section-soft { background: var(--surface-soft); }
.section-heading { max-width: 680px; margin-bottom: 2.5rem; }
.section-heading p { color: var(--muted); font-size: 1.05rem; }
.section-kicker {
  display: block;
  margin-bottom: 0.65rem;
  color: var(--blue);
  font-size: 0.76rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

/* About and profile */
.about-grid { display: grid; grid-template-columns: 1.15fr 0.85fr; gap: 3rem; align-items: start; }
.about-copy { color: var(--muted); }
.profile-panel {
  padding: 1.7rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: #fff;
  box-shadow: var(--shadow);
}
.profile-panel h3 { margin-bottom: 1rem; }
.profile-detail { display: flex; justify-content: space-between; gap: 1rem; padding: 0.75rem 0; border-bottom: 1px solid var(--border); }
.profile-detail:last-child { border-bottom: 0; }
.profile-detail strong { color: var(--navy); }
.profile-detail span { color: var(--muted); text-align: right; }

/* Cards and portfolio projects */
.card-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.25rem; }
.card, .project-card {
  height: 100%;
  padding: 1.6rem;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: 0 5px 18px rgba(16,29,50,0.035);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}
.card:hover, .project-card:hover { transform: translateY(-5px); border-color: #c6d5f2; box-shadow: var(--shadow); }
.card-icon {
  display: grid;
  width: 48px;
  height: 48px;
  margin-bottom: 1.2rem;
  place-items: center;
  border-radius: 14px;
  background: #eaf1ff;
  color: var(--blue);
  font-size: 1.35rem;
}
.card p, .project-card p { color: var(--muted); }
.project-image {
  overflow: hidden;
  aspect-ratio: 16 / 9;
  margin: -1.6rem -1.6rem 1.35rem;
  border-radius: var(--radius) var(--radius) 0 0;
  background: linear-gradient(135deg, #dce8fa, #e2f4f1);
}
.project-image img { width: 100%; height: 100%; object-fit: cover; transition: transform 250ms ease; }
.project-card:hover .project-image img { transform: scale(1.04); }
.project-tags, .skill-list { display: flex; flex-wrap: wrap; gap: 0.5rem; }
.tag, .skill {
  display: inline-flex;
  padding: 0.35rem 0.7rem;
  border: 1px solid #dce5f3;
  border-radius: 999px;
  background: #f6f8fc;
  color: #455873;
  font-size: 0.78rem;
  font-weight: 600;
}
.project-link { display: inline-flex; margin-top: 1rem; font-weight: 700; }

/* Skills */
.skills-layout { display: grid; grid-template-columns: 1fr 1fr; gap: 2.5rem; }
.skill-group { padding: 1.5rem; border: 1px solid var(--border); border-radius: var(--radius); background: #fff; }
.skill-group h3 { margin-bottom: 1rem; }
.skill-list { gap: 0.65rem; }
.skill { padding: 0.55rem 0.85rem; background: #fff; font-size: 0.85rem; }

/* Experience timeline */
.timeline { position: relative; max-width: 850px; margin-left: 0.5rem; padding-left: 2rem; border-left: 2px solid #dce5f3; }
.timeline-item { position: relative; padding: 0 0 2.2rem 1rem; }
.timeline-item:last-child { padding-bottom: 0; }
.timeline-item::before {
  position: absolute;
  top: 0.35rem;
  left: -2.47rem;
  width: 13px;
  height: 13px;
  border: 3px solid #fff;
  border-radius: 50%;
  background: var(--blue);
  box-shadow: 0 0 0 2px var(--blue);
  content: '';
}
.timeline-date { color: var(--blue); font-size: 0.82rem; font-weight: 800; letter-spacing: 0.04em; }
.timeline-item h3 { margin: 0.35rem 0; }
.timeline-item p { color: var(--muted); }

/* Contact and footer */
.contact-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 2rem;
  padding: clamp(2rem, 5vw, 3.5rem);
  border-radius: 24px;
  background: linear-gradient(120deg, var(--navy), #1b3a5c);
  color: #fff;
}
.contact-card h2 { color: #fff; }
.contact-card p { max-width: 580px; margin-bottom: 0; color: #d0d9e7; }
.site-footer { padding: 2rem 0; background: #0c1728; color: #aebbd0; }
.footer-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; }
.footer-links { display: flex; flex-wrap: wrap; gap: 1.2rem; }
.footer-links a { color: #d0d9e7; font-size: 0.9rem; }
.footer-links a:hover { color: #fff; }

/* Forms */
.contact-form { display: grid; gap: 1rem; max-width: 680px; }
.form-group { display: grid; gap: 0.4rem; }
.form-group label { color: var(--navy); font-weight: 700; }
.form-group input, .form-group textarea {
  width: 100%;
  padding: 0.85rem 1rem;
  border: 1px solid var(--border);
  border-radius: 12px;
  outline: none;
  background: #fff;
  color: var(--ink);
}
.form-group input:focus, .form-group textarea:focus { border-color: var(--blue); box-shadow: 0 0 0 3px rgba(40,100,220,0.12); }
.form-group textarea { min-height: 150px; resize: vertical; }

/* Accessibility and responsive behavior */
:focus-visible { outline: 3px solid var(--teal); outline-offset: 3px; }
::selection { background: #d7e5ff; color: var(--navy); }

@media (max-width: 850px) {
  .hero-layout { grid-template-columns: 1fr; gap: 2.5rem; }
  .hero-content { max-width: 100%; }
  .profile-photo { width: 220px; }
  .about-grid, .skills-layout { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .contact-card { align-items: flex-start; flex-direction: column; }
}

@media (max-width: 600px) {
  .container { width: min(100% - 2rem, var(--content-width)); }
  .nav { min-height: 68px; align-items: flex-start; flex-direction: column; justify-content: center; gap: 0.4rem; padding: 0.8rem 0; }
  .nav-links { width: 100%; gap: 1rem; overflow-x: auto; padding-bottom: 0.2rem; }
  .nav-links a { flex: 0 0 auto; font-size: 0.82rem; }
  .hero { padding: 4.5rem 0; }
  .profile-photo { width: 185px; }
  .card-grid { grid-template-columns: 1fr; }
  .footer-inner { align-items: flex-start; flex-direction: column; }
  .profile-detail { align-items: flex-start; flex-direction: column; gap: 0.15rem; }
  .profile-detail span { text-align: left; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; animation-duration: 0.01ms !important; }
}
