/* =====================================================================
   Aditya More - Personal Portfolio (COMP 426, A01)

   BASE COLOR PALETTE (the five chosen colors)
   https://coolors.co/f4f8fb-ffffff-4b9cd3-13293d-56707f
     #F4F8FB  pale sky        page background
     #FFFFFF  white           cards, surfaces, alternating sections
     #4B9CD3  Carolina blue   primary accent, links, hover states
     #13293D  deep navy       headings, footer, current-course card
     #56707F  slate gray      secondary body text

   DERIVED TINTS (mixed from the palette above, not in the Coolors link)
     #DCEAF5  pale blue       skill chips, course codes, header gradient
     #DFE8EE  light gray      card borders and dividers
     #B9CEDE  muted blue      body text sitting on the navy backgrounds

   Shadows are #13293D at 6% and 10% opacity; the sticky nav uses white
   at 88% opacity so content blurs behind it.

   EXTERNAL RESOURCES
   The only files this page loads from outside the project are the two
   Google Fonts, requested by the <link> tags in index.html:
     Outfit   headings, buttons, nav logo   (fallback: Trebuchet MS)
     Inter    body text                     (fallback: system sans)
   Everything else (styles.css, the profile photo, the GitHub and
   LinkedIn logos as inline SVG) is local to this repository.
   ===================================================================== */

/* ---------- Design tokens ---------- */
:root {
  --bg: #f4f8fb;
  --surface: #ffffff;
  --primary: #4b9cd3;
  --primary-soft: #dceaf5;
  --navy: #13293d;
  --muted: #56707f;
  --border: #dfe8ee;
  --on-navy: #b9cede;

  --font-display: "Outfit", "Trebuchet MS", sans-serif;
  --font-body: "Inter", -apple-system, "Segoe UI", sans-serif;

  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(19, 41, 61, 0.06);
  --shadow-md: 0 10px 28px rgba(19, 41, 61, 0.1);
  --max-width: 1080px;
}

/* ---------- Base ---------- */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background-color: var(--bg);
  color: var(--navy);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.2;
  margin: 0;
}

p {
  margin: 0 0 1rem;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.2s ease;
}

a:hover {
  color: var(--navy);
}

ul {
  list-style: none;
  margin: 0;
  padding: 0;
}

img {
  max-width: 100%;
  display: block;
}

/* ---------- Navigation (flexbox) ---------- */
.navbar {
  position: sticky;
  top: 0;
  z-index: 10;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem 1rem;
  padding: 0.9rem 2rem;
  background-color: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.nav-logo {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background-color: var(--navy);
  color: var(--surface);
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 0.9rem;
  letter-spacing: 0.02em;
}

.nav-logo:hover {
  background-color: var(--primary);
  color: var(--surface);
}

/* flexbox: horizontal nav links, wrapping on narrow screens */
.nav-links {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 0.4rem 1.75rem;
}

.nav-links a {
  color: var(--muted);
  font-size: 0.95rem;
  font-weight: 500;
  padding-bottom: 2px;
  border-bottom: 2px solid transparent;
  transition: color 0.2s ease, border-color 0.2s ease;
}

.nav-links a:hover {
  color: var(--navy);
  border-bottom-color: var(--primary);
}

/* ---------- Header ---------- */
.header {
  background: linear-gradient(160deg, var(--surface) 0%, var(--primary-soft) 100%);
  border-bottom: 1px solid var(--border);
  padding: 5rem 2rem 5.5rem;
}

/* flexbox: photo beside the intro text */
.header-inner {
  display: flex;
  align-items: center;
  gap: 3rem;
  max-width: var(--max-width);
  margin: 0 auto;
}

.profile-photo {
  width: 210px;
  height: 210px;
  flex-shrink: 0;
  border-radius: 50%;
  object-fit: cover;
  border: 6px solid var(--surface);
  box-shadow: var(--shadow-md);
}

.header-text {
  flex: 1;
}

.eyebrow {
  margin: 0 0 0.35rem;
  color: var(--primary);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.header h1 {
  font-size: clamp(2.5rem, 6vw, 3.6rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  margin-bottom: 0.75rem;
}

.tagline {
  max-width: 46ch;
  color: var(--muted);
  font-size: 1.1rem;
}

/* flexbox: side-by-side call-to-action buttons */
.header-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.75rem;
}

.button {
  display: inline-block;
  padding: 0.7rem 1.5rem;
  border-radius: 999px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease,
    background-color 0.2s ease, color 0.2s ease;
}

.button-primary {
  background-color: var(--navy);
  color: var(--surface);
  box-shadow: var(--shadow-sm);
}

.button-primary:hover {
  background-color: var(--primary);
  color: var(--surface);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.button-ghost {
  border: 2px solid var(--navy);
  color: var(--navy);
}

.button-ghost:hover {
  background-color: var(--navy);
  color: var(--surface);
  transform: translateY(-2px);
}

/* flexbox: social icon row beside the buttons */
.social-links {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin-left: 0.35rem;
  padding-left: 0.85rem;
  border-left: 1px solid var(--border);
}

.social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background-color: var(--surface);
  color: var(--navy);
  box-shadow: var(--shadow-sm);
  transition: background-color 0.2s ease, color 0.2s ease,
    transform 0.2s ease, box-shadow 0.2s ease;
}

.social-link svg {
  width: 21px;
  height: 21px;
  fill: currentColor;
}

.social-link:hover {
  background-color: var(--navy);
  color: var(--surface);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

/* ---------- Section scaffolding ---------- */
.section {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 4.5rem 2rem;
}

.section-alt {
  max-width: none;
  background-color: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding-left: max(2rem, calc((100% - var(--max-width)) / 2));
  padding-right: max(2rem, calc((100% - var(--max-width)) / 2));
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 0.5rem;
}

.section-title::after {
  content: "";
  display: block;
  width: 56px;
  height: 4px;
  margin-top: 0.7rem;
  border-radius: 2px;
  background-color: var(--primary);
}

.section-intro {
  color: var(--muted);
  margin: 1rem 0 2.25rem;
}

/* ---------- About (flexbox: text + fact card) ---------- */
.about-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2.5rem;
  margin-top: 2rem;
}

.about-body {
  flex: 2 1 380px;
}

.about-body strong {
  color: var(--primary);
}

.about-card {
  flex: 1 1 260px;
  align-self: flex-start;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-top: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 1.5rem 1.75rem;
  box-shadow: var(--shadow-sm);
}

.about-card h3 {
  font-size: 1.15rem;
  margin-bottom: 1rem;
}

/* flexbox: label / value rows */
.fact-list li {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.6rem 0;
  border-bottom: 1px dashed var(--border);
  font-size: 0.95rem;
}

.fact-list li:last-child {
  border-bottom: none;
}

.fact-label {
  color: var(--muted);
  font-weight: 500;
}

.cert-note {
  margin: 1rem 0 0;
  padding-top: 0.9rem;
  border-top: 1px solid var(--border);
  color: var(--muted);
  font-size: 0.85rem;
  line-height: 1.5;
}

/* ---------- Classes (flexbox card grid) ---------- */
.class-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
}

.class-card {
  flex: 1 1 260px;
  max-width: 100%;
  background-color: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.class-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
  box-shadow: var(--shadow-md);
}

.class-code {
  display: inline-block;
  margin-bottom: 0.65rem;
  padding: 0.2rem 0.7rem;
  border-radius: 999px;
  background-color: var(--primary-soft);
  color: var(--navy);
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.8rem;
  letter-spacing: 0.06em;
}

.class-card h3 {
  font-size: 1.1rem;
  margin-bottom: 0.5rem;
}

.class-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.94rem;
  line-height: 1.6;
}

.class-card-current {
  background-color: var(--navy);
  border-color: var(--navy);
}

.class-card-current h3 {
  color: var(--surface);
}

.class-card-current p {
  color: var(--on-navy);
}

.class-card-current .class-code {
  background-color: var(--primary);
  color: var(--surface);
}

/* ---------- Skills (flexbox columns + chips) ---------- */
.skills-columns {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
}

.skill-group {
  flex: 1 1 280px;
  background-color: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
}

.skill-group h3 {
  font-size: 1.05rem;
  margin-bottom: 1rem;
  color: var(--navy);
}

.skill-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.skill-chip {
  padding: 0.4rem 0.9rem;
  border-radius: 999px;
  background-color: var(--primary-soft);
  color: var(--navy);
  font-size: 0.9rem;
  font-weight: 500;
  transition: background-color 0.2s ease, color 0.2s ease,
    transform 0.2s ease;
}

.skill-chip:hover {
  background-color: var(--primary);
  color: var(--surface);
  transform: translateY(-2px);
}

/* ---------- Experience (flexbox stack) ---------- */
.exp-list {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.exp-card {
  background-color: var(--bg);
  border: 1px solid var(--border);
  border-left: 4px solid var(--primary);
  border-radius: var(--radius);
  padding: 1.6rem 1.75rem;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.exp-card:hover {
  transform: translateX(3px);
  box-shadow: var(--shadow-md);
}

/* flexbox: role on the left, dates pushed to the right */
.exp-head {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  justify-content: space-between;
  gap: 0.5rem 1.5rem;
  margin-bottom: 0.9rem;
}

.exp-head h3 {
  font-size: 1.15rem;
  margin-bottom: 0.2rem;
}

.exp-org {
  margin: 0;
  color: var(--primary);
  font-weight: 500;
  font-size: 0.95rem;
}

.exp-date {
  margin: 0;
  color: var(--muted);
  font-size: 0.85rem;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.exp-points li {
  position: relative;
  padding-left: 1.4rem;
  margin-bottom: 0.6rem;
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.65;
}

.exp-points li:last-child {
  margin-bottom: 0;
}

.exp-points li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.62em;
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background-color: var(--primary);
}

.exp-points strong {
  color: var(--navy);
  font-weight: 600;
}

/* ---------- Projects ---------- */
.project-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.project-card {
  display: flex;
  flex-direction: column;
  flex: 1 1 280px;
  background-color: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.75rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.project-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-md);
}

.project-card .project-date {
  flex-grow: 0;
  margin: 0 0 0.4rem;
  color: var(--muted);
  font-size: 0.8rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.project-card h3 {
  font-size: 1.2rem;
  margin-bottom: 0.6rem;
}

.project-card p {
  color: var(--muted);
  font-size: 0.95rem;
  flex-grow: 1;
}

.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-top: 0.5rem;
}

.tag {
  padding: 0.2rem 0.65rem;
  border: 1px solid var(--primary);
  border-radius: 999px;
  color: var(--primary);
  font-size: 0.78rem;
  font-weight: 500;
  letter-spacing: 0.03em;
}

.project-link {
  margin-top: 1rem;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.9rem;
}

.project-link:hover {
  color: var(--navy);
}

/* ---------- Footer ---------- */
.footer {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 3rem 2rem;
  background-color: var(--navy);
  color: var(--on-navy);
  text-align: center;
}

.footer-name {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 1.2rem;
  color: var(--surface);
}

.footer-note {
  margin: 0;
  font-size: 0.9rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
  margin-top: 0.75rem;
}

.footer-links a {
  color: var(--surface);
  font-size: 0.9rem;
  border-bottom: 1px solid transparent;
  transition: border-color 0.2s ease;
}

.footer-links a:hover {
  color: var(--surface);
  border-bottom-color: var(--primary);
}

/* ---------- Even card columns ----------
   flex-grow fills a short last row, so cap each card at a column width. */
@media (min-width: 640px) {
  .skill-group {
    flex-basis: calc(50% - 1rem);
    max-width: calc(50% - 1rem);
  }

  .class-card {
    max-width: calc((100% - 1.25rem) / 2);
  }

  .project-card {
    max-width: calc((100% - 1.5rem) / 2);
  }
}

@media (min-width: 920px) {
  .class-card {
    max-width: calc((100% - 2.5rem) / 3);
  }

  .project-card {
    max-width: calc((100% - 3rem) / 3);
  }
}

/* ---------- Responsive ---------- */
@media (max-width: 760px) {
  .navbar {
    padding: 0.75rem 1.25rem;
  }

  .nav-links {
    gap: 0.35rem 0.9rem;
  }

  .header {
    padding: 3.5rem 1.5rem 4rem;
  }

  .header-inner {
    flex-direction: column;
    text-align: center;
    gap: 2rem;
  }

  .tagline {
    max-width: none;
  }

  .header-actions {
    justify-content: center;
  }

  .social-links {
    margin-left: 0;
    padding-left: 0;
    border-left: none;
  }

  .section-title::after {
    margin-left: 0;
  }

  .section {
    padding: 3rem 1.5rem;
  }
}

@media (max-width: 520px) {
  .nav-links {
    font-size: 0.85rem;
  }

  .profile-photo {
    width: 160px;
    height: 160px;
  }
}
