:root {
  --page-bg: #f5f7fb;
  --surface: rgba(255, 255, 255, 0.9);
  --surface-strong: #ffffff;
  --ink: #24324a;
  --muted: #5f6f86;
  --border-soft: rgba(28, 47, 91, 0.12);
  --accent: #2563eb;
  --accent-dark: #1d4ed8;
  --accent-soft: rgba(37, 99, 235, 0.08);
  --accent-border: rgba(37, 99, 235, 0.12);
  --accent-glow: rgba(37, 99, 235, 0.35);
  --shadow-lg: 0 24px 60px rgba(28, 47, 91, 0.14);
  --shadow-md: 0 16px 40px rgba(28, 47, 91, 0.12);
}

html {
  background:
    radial-gradient(circle at top right, var(--accent-border), transparent 28%),
    linear-gradient(180deg, #fbfcff 0%, var(--page-bg) 100%);
}

body {
  background: transparent;
  color: var(--ink);
  overflow-x: hidden;
}

p,
li,
div,
span {
  color: inherit;
}

img,
iframe,
table {
  max-width: 100%;
}

main {
  min-width: 0;
}

.skip-link {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 2000;
  padding: 0.75rem 1rem;
  background: var(--accent-dark);
  color: #fff;
  border-radius: 0.75rem;
  transition: top 0.2s ease;
}

.skip-link:focus {
  top: 1rem;
  color: #fff;
}

#sideNav {
  background:
    linear-gradient(180deg, rgba(16, 32, 67, 0.97), rgba(28, 47, 91, 0.92)),
    #1c2f5b !important;
  box-shadow: 12px 0 48px rgba(15, 23, 42, 0.12);
}

#sideNav .img-profile {
  box-shadow: 0 14px 28px rgba(15, 23, 42, 0.25);
}

#sideNav .nav-link {
  letter-spacing: 0.06em;
}

#sideNav .navbar-brand {
  min-width: 0;
}

section.resume-section {
  border-bottom: 1px solid var(--border-soft);
}

.project-subsection+.project-subsection {
  padding-top: 2.5rem;
}

.hero-panel,
#projects-content,
.resume-section .my-auto {
  position: relative;
  min-width: 0;
  max-width: 100%;
}

.hero-panel {
  gap: 2rem;
  margin-bottom: 2rem;
  padding: 2rem;
  max-width: 100%;
  background: linear-gradient(145deg,
      rgba(255, 255, 255, 0.96),
      rgba(242, 246, 255, 0.88));
  border: 1px solid var(--border-soft);
  border-radius: 1.75rem;
  box-shadow: var(--shadow-lg);
}

.hero-panel>.mr-auto {
  min-width: 0;
}

.subheading {
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.subheading a,
.resume-section a {
  overflow-wrap: anywhere;
  word-break: break-word;
}

.resume-content {
  min-width: 0;
}

.resume-date {
  flex-shrink: 0;
}

.resume-section p,
.resume-section li {
  line-height: 1.7;
}

.resume-section ul:not(.navbar-nav):not(.tags):not(.list-inline) {
  padding-left: 1.25rem;
}

.resume-section .list-inline {
  padding-left: 0;
}

.list-social-icons a {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

#skills-content ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem 1rem;
  padding-left: 0;
  list-style: none;
}

#skills-content .list-inline-item {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin: 0;
  min-width: 0;
}

#skills-content .list-inline-item i {
  flex: 0 0 auto;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 0.45rem 0.8rem;
  border-radius: 999px;
  font-size: 0.85rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  background: var(--accent-soft);
  color: var(--accent-dark);
}

.lead-copy {
  max-width: 42rem;
  font-size: 1.08rem;
  line-height: 1.8;
  color: var(--muted);
}

.lead-copy p:last-child {
  margin-bottom: 0;
}

.hero-actions .btn {
  min-width: 11rem;
  border-radius: 999px;
  padding: 0.85rem 1.35rem;
  font-weight: 700;
  box-shadow: none;
}

.hero-actions .btn-primary {
  background: linear-gradient(135deg, var(--accent), var(--accent-dark));
  border-color: transparent;
}

.hero-actions .btn-outline-primary {
  border-width: 2px;
}

.hero-aside {
  width: 100%;
  max-width: 22rem;
}

.profile-card {
  overflow: hidden;
  background: var(--surface-strong);
  border: 1px solid var(--border-soft);
  border-radius: 1.5rem;
  box-shadow: var(--shadow-md);
}

.profile-card-image {
  display: block;
  width: 100%;
  aspect-ratio: 1 / 1;
  object-fit: cover;
}

.profile-card-body {
  padding: 1.25rem 1.25rem 1rem;
}

.profile-card-label {
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.profile-highlights {
  margin: 0;
  padding-left: 1.15rem;
  color: var(--ink);
}

.profile-highlights li+li {
  margin-top: 0.5rem;
}

.about-sections>p:first-child {
  /* The intro copy is already rendered inside the hero. */
  display: none;
}

.meta-badges {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin: 1.5rem 0 0.5rem;
}

.meta-badges a {
  display: inline-flex;
  align-items: center;
}

.meta-badges img {
  display: block;
  max-width: 100%;
  height: auto;
  border-radius: 999px;
  box-shadow: 0 10px 24px rgba(28, 47, 91, 0.08);
}

.tag {
  background: var(--accent-soft);
  color: var(--ink);
  border: none;
  border-radius: 999px 0 0 999px;
  filter: drop-shadow(0 0 0.75px var(--accent-glow));
}

.tag::before {
  background: var(--page-bg);
  box-shadow: inset 0 1px rgba(28, 47, 91, 0.18);
}

.tag::after {
  background: transparent;
  border-left-color: var(--accent-soft);
}

.tag:hover,
.tag:focus {
  background-color: var(--accent);
  color: #fff;
}

.tag:hover::after,
.tag:focus::after {
  border-left-color: var(--accent);
}

.certification-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(10.5rem, 12rem));
  justify-content: flex-start;
  gap: 0.75rem;
  margin-top: 0.75rem;
  padding-left: 0;
}

.certification-list .list-inline-item {
  width: auto;
  margin: 0;
}

.certification-list .list-inline-item,
.board-list .list-inline-item {
  margin-bottom: 1rem;
}

.certification-badge,
.board-card {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 5.5rem;
  padding: 0.9rem 1rem;
  background: var(--surface);
  border: 1px solid var(--border-soft);
  border-radius: 1rem;
  box-shadow: 0 12px 28px rgba(28, 47, 91, 0.08);
}

.certification-badge {
  flex-direction: column;
  justify-content: flex-start;
  gap: 0.55rem;
  width: 12rem;
  min-height: 8.5rem;
  padding: 0.75rem;
  text-decoration: none;
  transition:
    transform 0.2s ease,
    box-shadow 0.2s ease,
    border-color 0.2s ease;
}

.certification-badge[href]:hover {
  transform: translateY(-2px);
  border-color: rgba(37, 99, 235, 0.26);
  box-shadow: 0 16px 30px rgba(28, 47, 91, 0.12);
}

.certification-badge[href]:focus-visible {
  outline: none;
  border-color: rgba(37, 99, 235, 0.35);
  box-shadow:
    0 0 0 3px rgba(37, 99, 235, 0.15),
    0 16px 30px rgba(28, 47, 91, 0.12);
}

.certification-badge[data-toggle="tooltip"]:not(a) {
  cursor: help;
}

.certification-media {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 4.2rem;
  padding: 0.45rem;
  background: var(--surface-strong);
  border: 1px solid var(--border-soft);
  border-radius: 0.8rem;
}

.certification-title {
  display: block;
  margin: 0;
  width: 100%;
  text-align: center;
  font-size: 0.74rem;
  font-weight: 700;
  line-height: 1.32;
  color: var(--ink);
}

.board-card>a {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  border-radius: 0.4rem;
  overflow: hidden;
}

.board-label--subtle {
  color: var(--muted);
  font-weight: 600;
}

.board-card img {
  border-radius: 0.4rem;
  object-fit: contain;
}

.certification-badge img,
.certification-list a img {
  display: block;
  width: 100%;
  max-width: 7rem;
  height: 3.6rem;
  border-radius: 0.4rem;
  object-fit: contain;
}

.project-card-image {
  display: block;
  width: min(100%, 150px);
  max-width: 150px;
  height: auto;
  border-radius: 0.9rem;
  box-shadow: 0 14px 28px rgba(28, 47, 91, 0.12);
}

.resume-item {
  gap: 1rem;
}

.breadcrumb {
  background: transparent;
  align-items: center;
  margin-left: 1.25rem;
  margin-bottom: 1.25rem;
  padding-left: 0;
  padding-right: 0;
}

nav[aria-label="breadcrumb"] {
  margin-top: 0.75rem;
}

.breadcrumb-item {
  min-width: 0;
}

.breadcrumb-item a {
  line-height: 1.35;
}

footer p {
  color: var(--muted) !important;
}

.contact-layout {
  max-width: 64rem;
  margin: 0 auto;
}

.contact-details li+li {
  margin-top: 0.6rem;
}

.contact-social-link {
  color: var(--ink);
  font-weight: 700;
}

.contact-qr-column {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid rgba(95, 111, 134, 0.35);
}

@media (min-width: 992px) {
  .contact-layout {
    position: relative;
    align-items: stretch;
  }

  .contact-info-column {
    padding-right: 2rem !important;
    border-right: 0;
  }

  .contact-qr-column {
    margin-top: 0;
    padding-top: 0;
    border-top: 0;
    padding-left: 2rem !important;
  }

  .contact-layout::before {
    content: "";
    position: absolute;
    top: 0;
    bottom: 0;
    left: 58.333333%;
    width: 1px;
    background: rgba(95, 111, 134, 0.45);
  }
}

@media (max-width: 991.98px) {
  body {
    padding-top: 58px;
    background: linear-gradient(180deg,
        rgba(255, 255, 255, 0.96),
        rgba(245, 247, 251, 0.96));
  }

  #sideNav {
    box-shadow: 0 10px 28px rgba(15, 23, 42, 0.16);
  }

  #sideNav .navbar-brand {
    max-width: calc(100vw - 5.25rem);
    margin-right: 0.5rem;
    line-height: 1.2;
    white-space: normal;
  }

  #sideNav .navbar-collapse {
    max-height: calc(100vh - 4rem);
    overflow-y: auto;
  }

  #sideNav .navbar-nav {
    padding: 0.5rem 0 0.25rem;
  }

  #sideNav .nav-link {
    padding: 0.75rem 0.25rem;
  }

  section.resume-section {
    min-height: auto;
    padding-top: 2.75rem !important;
    padding-bottom: 2.75rem !important;
  }

  section.resume-section:first-of-type {
    padding-top: 1.5rem !important;
  }

  .hero-panel {
    padding: 1.5rem;
    border-radius: 1.25rem;
  }

  .hero-aside {
    max-width: none;
  }
}

@media (max-width: 768px) {
  h1 {
    font-size: clamp(3rem, 16vw, 4rem);
    line-height: 0.95;
  }

  h2 {
    font-size: clamp(2.25rem, 11vw, 2.8rem);
    line-height: 1;
  }

  h3 {
    font-size: 1.65rem;
    line-height: 1.1;
  }

  .subheading {
    font-size: 1.15rem;
  }

  .lead-copy {
    font-size: 1rem;
    line-height: 1.7;
  }

  .hero-panel {
    gap: 1.25rem;
    margin-left: -0.25rem;
    margin-right: -0.25rem;
    padding: 1.15rem;
  }

  .hero-panel>.mr-auto {
    width: 100%;
    margin-right: 0 !important;
  }

  .hero-actions {
    display: grid;
    gap: 0.75rem;
    width: 100%;
  }

  .hero-actions .btn {
    width: 100%;
    min-width: 0;
    margin-bottom: 0 !important;
    margin-right: 0 !important;
  }

  .profile-card-body {
    padding: 1rem;
  }

  .profile-story p {
    margin-bottom: 0.85rem;
  }

  .meta-badges {
    gap: 0.55rem;
  }

  .meta-badges a {
    max-width: 100%;
  }

  .certification-badge {
    width: 100%;
    min-height: 8rem;
  }

  .board-card {
    flex-direction: column;
    align-items: flex-start;
    width: 100%;
    text-align: left !important;
  }

  .board-list,
  .board-list .list-inline-item {
    display: block;
    width: 100%;
  }

  .board-card .text-left {
    margin-top: 0.75rem;
    margin-left: 0 !important;
  }

  .certification-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    justify-content: stretch;
  }

  #projects-content .resume-item {
    align-items: flex-start;
  }

  #projects-content .project-card-image {
    width: 100%;
    max-width: 100%;
    margin-right: 0 !important;
    margin-bottom: 1rem;
  }

  .project-subsection+.project-subsection {
    padding-top: 1.75rem;
  }

  .resume-item {
    gap: 0.5rem;
  }

  .resume-date {
    width: 100%;
    min-width: 0 !important;
  }

  nav[aria-label="breadcrumb"] {
    margin-top: 1.875rem;
  }
}

@media (max-width: 575.98px) {
  body {
    padding-top: 54px;
  }

  .container-fluid {
    overflow-x: hidden;
  }

  section.resume-section {
    padding-left: 1rem !important;
    padding-right: 1rem !important;
    padding-top: 2.25rem !important;
    padding-bottom: 2.25rem !important;
  }

  #sideNav {
    padding-left: 0.9rem;
    padding-right: 0.9rem;
  }

  #sideNav .navbar-brand {
    font-size: 0.98rem;
  }

  h1 {
    font-size: clamp(2.55rem, 13.5vw, 3.25rem);
  }

  h1 .text-primary {
    display: block;
  }

  .subheading {
    font-size: 1.02rem;
  }

  .hero-panel {
    margin-left: 0;
    margin-right: 0;
    width: 100%;
    max-width: 100%;
    border-radius: 1rem;
    box-shadow: 0 14px 36px rgba(28, 47, 91, 0.1);
  }

  .lead-copy,
  .profile-story {
    min-width: 0;
    overflow-wrap: break-word;
  }

  .eyebrow {
    font-size: 0.76rem;
    line-height: 1.2;
  }

  .certification-list {
    grid-template-columns: 1fr;
  }

  .certification-badge {
    min-height: 0;
  }

  .certification-media {
    min-height: 3.75rem;
  }

  #skills-content ul {
    gap: 0.5rem 0.75rem;
  }

  .tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }

  .tags li {
    float: none;
  }

  .tag {
    height: auto;
    min-height: 26px;
    margin: 0;
    white-space: normal;
  }
}

@media (min-width: 768px) {

  /* Project cards use an explicit two-column layout on desktop to keep image/text spacing stable. */
  #projects-content .resume-item.flex-md-row {
    display: grid !important;
    grid-template-columns: 150px minmax(0, 1fr);
    column-gap: 1rem;
    align-items: start;
  }

  #projects-content .resume-item .resume-date {
    min-width: 0;
    padding-left: 0.25rem;
  }

  #projects-content .project-card-image {
    width: 150px;
    margin-right: 0 !important;
  }
}