:root {
  --canvas: #1d1d1d;
  --paper: #ffffff;
  --ink: #111111;
  --muted-ink: #4f5860;
  --accent: #0a4c70;
  --divider: #111111;
  --rating: #f5a623;
  --page-width: 8.5in;
  --page-height: 11in;
  --print-page-height: 16in;
  --page-padding: 0.25in 0.21in;
  --section-gap: 17px;
  font-family: "Open Sans", Arial, sans-serif;
  color: var(--ink);
}

@page {
  size: 8.5in var(--print-page-height);
  margin: 0;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--canvas);
}

.resume {
  position: relative;
  width: min(100%, var(--page-width));
  min-height: var(--page-height);
  margin: auto;
  padding: var(--page-padding);
  background: var(--paper);
}

h1,
h2,
h3,
p,
ul,
dl,
dd {
  margin: 0;
}

a {
  color: inherit;
  text-decoration: none;
}

strong {
  font-weight: 600;
}

.resume-header h1 {
  font-size: 20pt;
  font-weight: 600;
  line-height: 1.1;
}

@keyframes role-sweep {
  0% {
    background-position: 0% center;
  }

  100% {
    background-position: 100% center;
  }
}

.role {
  margin-top: 5px;
  font-size: 12.5pt;
  font-weight: 500;
  background: linear-gradient(90deg,
      var(--accent) 0%,
      var(--accent) 30%,
      #1a8acb 42%,
      #5bb8f5 50%,
      #1a8acb 58%,
      var(--accent) 70%,
      var(--accent) 100%);
  background-size: 300% auto;
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: role-sweep 4s linear infinite;
}

.contact-list,
.profile-list {
  display: flex;
  flex-wrap: wrap;
  margin-top: 8px;
  padding: 0;
  font-size: 10.5pt;
  font-style: normal;
  list-style: none;
}

.contact-list {
  gap: 10px 10px;
}

.profile-list {
  gap: 10px 30px;
}

.contact-list li+li {
  border-left: 1px solid #9ca3a8;
  padding-left: 10px;
}

.profile-list a:hover {
  text-decoration: underline;
  text-underline-offset: 2px;
}

.profile-link {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.linkedin-icon {
  width: 13px;
  height: 13px;
}

.github-icon {
  width: 16px;
  height: 16px;
}

.portfolio-icon {
  width: 14px;
  height: 14px;
}

.resume-section {
  margin-top: var(--section-gap);
}

.resume-section>h2 {
  padding-bottom: 2px;
  border-bottom: 1px solid var(--divider);
  font-size: 9pt;
  font-weight: 700;
  letter-spacing: 0.01em;
}

.summary {
  margin-top: 8px;
  font-size: 10.5pt;
  line-height: 1.4;
}

.entry {
  margin-top: 14px;
}

.entry-heading,
.entry-meta {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  font-size: 10.5pt;
}

.entry-heading h3 {
  font-size: 11pt;
  font-weight: 600;
}

.entry-meta {
  margin-top: 3px;
  color: var(--muted-ink);
  font-weight: 500;
}

.entry-date {
  min-width: 155px;
  text-align: right;
  font-weight: 500;
}

.highlights {
  margin-top: 8px;
  padding-left: 22px;
}

.highlights li {
  margin: 3px 0;
  padding-left: 4px;
  font-size: 10.5pt;
  line-height: 1.35;
}

.project {
  margin-top: 9px;
  font-size: 10.5pt;
  line-height: 1.4;
}

.project h3,
.skill-list dt,
.award h3,
.certificate h3 {
  font-size: 10.5pt;
  font-weight: 600;
}

.skill-list {
  margin-top: 9px;
}

.skill-list>div {
  margin-top: 9px;
}

.skill-list>div:first-child {
  margin-top: 0;
}

.skill-list dt {
  font-weight: 600;
}

.skill-list dd {
  font-size: 9.5pt;
  line-height: 1.4;
}

.award-list,
.certificate-list {
  display: grid;
  gap: 16px;
  margin-top: 9px;
}

.award-list {
  grid-template-columns: repeat(3, 1fr);
}

.certificate-list {
  grid-template-columns: repeat(2, 1fr);
}

.award p,
.certificate p {
  color: var(--muted-ink);
  font-size: 10pt;
}

@media print {
  .role {
    background: none;
    -webkit-background-clip: unset;
    background-clip: unset;
    -webkit-text-fill-color: unset;
    color: var(--accent);
    animation: none;
  }
}

@media print {
  .resume-section>h2 {
    position: relative;
    border-bottom: 0;
  }

  .resume-section>h2::after {
    position: absolute;
    right: 0;
    bottom: 0;
    left: 0;
    height: 1px;
    background: #8a8a8a;
    content: "";
    transform: scaleY(0.5);
    transform-origin: bottom;
  }

  body {
    background: var(--paper);
  }

  .resume {
    width: var(--page-width);
    margin: 0;
    box-shadow: none;
  }

  .profile-list a {
    color: var(--ink);
  }
}

.cv-rating {
  position: absolute;
  top: 0.25in;
  right: 0.25in;
  display: flex;
  flex-direction: row-reverse;
  gap: 0;
}

.cv-rating input[type="radio"] {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}

.cv-rating label {
  padding: 0 2px;
  color: #d1d5da;
  font-size: 15pt;
  line-height: 1;
  cursor: pointer;
  user-select: none;
}

.cv-rating label:hover,
.cv-rating label:hover~label,
.cv-rating label.drag-active,
.cv-rating label.drag-active~label {
  color: var(--rating);
  transform: scale(1.2);
}

.cv-rating-hint {
  position: absolute;
  top: calc(100% + 5px);
  right: 0;
  font-size: 7.5pt;
  font-weight: 500;
  color: var(--muted-ink);
  white-space: nowrap;
  transition: opacity 0.15s ease, transform 0.15s ease;
  pointer-events: none;
}

.cv-rating input:checked~label {
  color: var(--rating);
}


@media print {
  .cv-rating {
    display: none;
  }
}

.rp-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0 0 0 / 0.35);
  z-index: 200;
}

.rp-dialog {
  position: fixed !important;
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%) !important;
  margin: 0 !important;
  z-index: 201;
  width: min(320px, 88vw);
  padding: 22px;
  border: none;
  border-radius: 12px;
  background: #ffffff;
  box-shadow: 0 8px 32px rgba(0 0 0 / 0.18);
}

.rp-greeting {
  margin-bottom: 4px;
  font-size: 15pt;
  font-weight: 600;
  color: var(--ink);
  line-height: 1.2;
}

.rp-sub {
  margin-bottom: 18px;
  font-size: 10pt;
  color: var(--muted-ink);
}

.rp-form {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.rp-input {
  width: 100%;
  padding: 9px 12px;
  border: 1.5px solid #d1d5da;
  border-radius: 7px;
  font-family: inherit;
  font-size: 10pt;
  color: var(--ink);
  outline: none;
  transition: border-color 0.15s;
  box-sizing: border-box;
}

.rp-input:focus {
  border-color: var(--accent);
}

.rp-btn {
  flex: 1;
  margin-top: 10px;
  padding: 10px 0;
  border: none;
  border-radius: 7px;
  font-family: inherit;
  font-size: 10pt;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.15s;
}

.rp-btn:hover {
  opacity: 0.85;
}

.rp-btn--primary {
  background: var(--accent);
  color: #ffffff;
}

.rp-done {
  margin-top: 12px;
  font-size: 10.5pt;
  font-weight: 500;
  color: var(--accent);
  text-align: center;
}

@media print {

  .rp-overlay,
  .rp-dialog {
    display: none !important;
  }
}

@media (max-width: 600px) {
  .resume {
    margin: 0;
    padding: 24px 20px;
    box-shadow: none;
  }

  .entry-heading,
  .entry-meta {
    display: block;
  }

  .entry-date {
    min-width: 0;
    margin-top: 2px;
    text-align: left;
  }

  .award-list,
  .certificate-list {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .cv-rating {
    position: relative;
    justify-content: flex-end;
    margin: 20px 0px 40px 20px;
  }

  .cv-rating-hint {
    top: auto;
    bottom: calc(100% + 5px);
    left: 0;
    right: auto;
  }

  .cv-rating label {
    font-size: 18pt;
  }
}
