:root {
  --bg: #01012b;
  --surface: rgb(17, 17, 78);
  --hoover: #00ff15a9;
  --border: #ffffff44;
  --text: #ffffff;
  --muted: #c6c6c6;
  --max-width: 760px;
}
* {
  box-sizing: border-box;
}

::-webkit-scrollbar {
  width: 8px;
}

::-webkit-scrollbar-track {
  background: transparent;
}

::-webkit-scrollbar-thumb {
  background: linear-gradient(
    to bottom,
    rgba(108, 92, 231, 0),
    rgb(74, 63, 238),
    rgb(0, 255, 255),
    rgb(74, 63, 238),
    rgba(108, 92, 231, 0)
  );
  border-radius: 10px;
}

::-webkit-scrollbar-thumb:hover {
  background: linear-gradient(
    to bottom,
    rgba(108, 92, 231, 0),
    rgb(74, 63, 238),
    rgb(0, 255, 255),
    rgb(74, 63, 238),
    rgba(108, 92, 231, 0)
  );
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "Manrope", sans-serif;
  padding: 0.3rem;
}

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

h1,
h2,
h3,
p {
  margin: 0px;
  line-height: 1.6;
  font-size: 1rem;
  letter-spacing: 0.06rem;
}

.site-shell {
  width: min(calc(100% - 1.5rem), var(--max-width));
  margin: 0 auto;
  padding: 2.5rem 0 4rem;
}

.page {
  display: grid;
  gap: 3.5rem;
}

.hero,
.section {
  display: grid;
  gap: 1.15rem;
}

.hero-topline {
  display: flex;
  align-items: flex-start;
  gap: 1rem;
}

.project-screenshot {
  width: 100%;
}

.project-screenshot img {
  width: 100%;
  height: 100%;
  border-radius: 12px;
  object-fit: cover;
  display: block;
}

.hero-avatar img{
  padding: 4px;
  border-radius: 99px;
  width: 5rem;
  height: 5rem;
  background:white;
}

h1,
h2 {
  font-family: "Cormorant Garamond", serif;
  font-weight: 900;
  letter-spacing: -0.003em;
}

h1 {
  font-size: 30px;
  line-height: 1.2;
}

.hero-identity {
  display: grid;
  gap: 0.6rem;

}

h2 {
  color:aqua;
  font-size: clamp(2rem, 5vw, 2.8rem);
  line-height: 0.95;
}

h3 {
  font-size: 1.05rem;
  line-height: 1.3;
}

p {
  color: var(--muted);
  line-height: 1.75;
  font-size: 0.98rem;
}

.hero-role {
  color: rgb(64, 255, 0);
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.02em;
  text-transform: uppercase;
  min-height: 1.5rem;
}

.typing-role::after {
  content: "|";
  margin-left: 0.12rem;
  animation: blink 900ms steps(1) infinite;
  color: #ffffff;
}

.hero-copy,
.hero-status {
  max-width: 100%;
}

.contact-links,
.project-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.contact-links img {
  max-width: 20px;
  object-fit: contain;
  padding-right: 4px;
}

.contact-links a ,
.project-links a,
.project-links span,
.section-action a,
.section-action button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.65rem;
  padding: 0 1rem;
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.92rem;
  font-weight: 500;
  font-family: inherit;
  transition: transform 180ms ease, border-color 180ms ease, background-color 180ms ease;
}

.section-action button {
  cursor: pointer;
}

.section-action img{
  object-fit: contain;
  padding-right: 4px;
}

#projects .repo-pill {
  width: 2.1rem;
  overflow: hidden;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 0.75rem;
  min-height: 2rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  white-space: nowrap;
  position: relative;
  transition: width 1000ms ease, padding 1000ms ease, border-radius 1000ms ease,
    background-color 1000ms ease, transform 180ms ease;
}

#projects .repo-pill {
  width: 2.8rem;
  min-height: 2.8rem;
}

#projects .repo-pill:hover,
#projects .repo-pill:focus-visible {
  width: 16.75rem;
  padding: 0 0.9rem 0 0.15rem;
  border-radius: 999px;
  background: var(--surface);
  justify-content: flex-start;
}

.repo-pill-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.8rem;
  height: 2.8rem;
  flex: 0 0 2.8rem;
}

.repo-pill-icon img {
  width: 3rem;
  height: 3rem;
  object-fit: contain;
  padding-right: 0;
  max-width: none;
  filter: drop-shadow(0 0 10px rgba(255, 255, 255, 0.18));
}

.repo-pill-label {
  position: absolute;
  left: 3rem;
  top: 50%;
  transform: translate(10px, -50%);
  opacity: 0;
  transition: opacity 450ms ease, transform 1000ms ease;
  pointer-events: none;
}

.repo-pill:hover .repo-pill-label,
.repo-pill:focus-visible .repo-pill-label {
  opacity: 1;
  transform: translate(0, -50%);
}

.contact-links .contact-pill {
  width: 2.55rem;
  overflow: hidden;
  display: inline-flex;
  justify-content: flex-start;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.55rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  white-space: nowrap;
  position: relative;
  transition: width 1000ms ease, padding 1000ms ease, border-radius 1000ms ease,
    background-color 1000ms ease, transform 180ms ease;
}

.contact-links .contact-pill:hover,
.contact-links .contact-pill:focus-visible {
  width: 8.5rem;
  padding: 0 0.85rem 0 0.15rem;
  border-radius: 999px;
  background: var(--hoover);
  font-weight: 900;
}

.contact-pill-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.55rem;
  height: 2.55rem;
  flex: 0 0 2.55rem;
}

.contact-pill-icon img {
  width: 1.7rem;
  height: 1.7rem;
  object-fit: contain;
  padding-right: 0;
  max-width: none;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.15));
}

.contact-pill-label {
  position: absolute;
  left: 2.9rem;
  top: 50%;
  transform: translate(10px, -50%);
  opacity: 0;
  transition: opacity 450ms ease, transform 1000ms ease;
  pointer-events: none;
}

.contact-pill:hover .contact-pill-label,
.contact-pill:focus-visible .contact-pill-label {
  opacity: 1;
  transform: translate(0, -50%);
}

.hero-links .hero-pill {
  width: 2.65rem;
  overflow: hidden;
  display: inline-flex;
  justify-content: flex-start;
  align-items: center;
  gap: 0.65rem;
  min-height: 2.65rem;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
  white-space: nowrap;
  position: relative;
  transition: width 1000ms ease, padding 1000ms ease, border-radius 1000ms ease,
    background-color 1000ms ease, transform 180ms ease;
}

.hero-links .hero-pill:hover,
.hero-links .hero-pill:focus-visible {
  width: 8.75rem;
  padding: 0 0.85rem 0 0.15rem;
  border-radius: 999px;
  background: var(--hoover);
}

.hero-pill-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.65rem;
  height: 2.65rem;
  flex: 0 0 2.65rem;
}

.hero-pill-icon img {
  width: 1.75rem;
  height: 1.75rem;
  object-fit: contain;
  padding-right: 0;
  max-width: none;
  filter: drop-shadow(0 0 8px rgba(255, 255, 255, 0.15));
}

.hero-pill-label {
  position: absolute;
  left: 3rem;
  top: 50%;
  font-weight: 900;
  color: var(--text);
  transform: translate(10px, -50%);
  opacity: 0;
  transition: opacity 450ms ease, transform 1000ms ease;
  pointer-events: none;
}

.hero-pill:hover .hero-pill-label,
.hero-pill:focus-visible .hero-pill-label {
  opacity: 1;
  transform: translate(0, -50%);
}

.extra-projects[hidden] {
  display: none;
}

.contact-links a:hover,
.project-links a:hover,
.section-action a:hover,
.section-action button:hover {
  transform: translateY(-2px);
  background: var(--hoover);
}

.hero-links{
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-left: 1vw;
}

.hero-links img{
  max-width: 40px;
  object-fit: contain;
  padding-right: 4px;
}

.hero-links a:hover img{
  filter: drop-shadow(0 0 4px var(--hoover));
  transform: translateY(-2px);
}

.project-links span {
  opacity: 0.72;
  box-shadow: none;
}

.section-action {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: -0.25rem;
}

.projects-heading {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 0.75rem;
  flex-wrap: wrap;
}

.projects-heading .repo-pill {
  margin-left: 0;
}

.project-grid {
  display: grid;
  gap: 0.95rem;
}

.timeline-item {
  border-bottom: 10px solid transparent;
  padding: 12px 0;
  cursor: pointer;
}

.timeline-header:hover{
  border-top: 1px solid var(--hoover);
  border-right: 1px solid var(--hoover);
  border-radius: 10px 10px 0 0;
}

.timeline-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.timeline-header .right {
  display: flex;
  align-items: center;
  gap: 10px;
}

.toggle-icon {
  font-size: 2.5rem;
  font-weight: bold;
  transition: transform 0.3s ease;
}

.project-body {
  display: grid;
  gap: 0.22rem;
}

.timeline-details p{
  color: #d2d2d2;
  font-family: 'Arial', sans-serif ;
  line-height: 1.6;
  margin-bottom: 1rem;
}

.timeline-details {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}

.timeline-item.active .timeline-details {
  max-height: 200px;
  margin-top: 10px;
}

.timeline-item.active .toggle-icon {
  transform: rotate(45deg);
}

.timeline-company {
  color: var(--text);
  font-weight: 200;
  font-size: 0.9rem;
}

.timeline-date {
  font-size: 0.9rem;
  color: var(--text);
  white-space: nowrap;
}

.timeline-header {
  cursor: pointer;
}

.timeline-header .right, .timeline-company{
  opacity: 0.7;
}

.timeline-item:hover .timeline-header .right{
  opacity: 1;
  color: aqua;
}

.project-card {
  display: grid;
  grid-template-columns: minmax(160px, 25%) minmax(0, 1fr);
  align-items: start;
  gap: 0.95rem;
  background: var(--surface);
  border-radius: 16px;
  padding: 1rem;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background-color 180ms ease;
  position: relative;
  overflow: hidden;
}

.project-screenshot {
  grid-column: 1;
}

.project-body {
  grid-column: 2;
}

.project-body p {
  margin-top: 0.15rem;
}

.project-summary {
  display: -webkit-box;
  line-clamp: 2;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  min-height: 3.2rem;
}

.project-card:hover,
.project-card:focus-visible {border: 1px solid var(--hoover);
  transform: translateY(-4px);
  box-shadow: 0px 20px 40px rgba(255, 255, 255, 0.212);
}

.project-card::after {
  content: "click anywhere to view more";
  top: 1rem;
  right: 1rem;
  background: transparent;
  color: var(--muted);
  font-size: 0.52rem;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  opacity: 0;
  transform: translateY(-8px);
  transition: opacity 180ms ease, transform 180ms ease;
  pointer-events: none;
}

.project-card:focus-visible {
  outline: 2px solid rgba(255, 255, 255, 0.75);
  outline-offset: 3px;
}

.project-card:hover::after,
.project-card:focus-visible::after {
  opacity: 1;
  transform: translateY(0);
}

body.modal-open {
  overflow: hidden;
}

body.modal-open .site-shell {
  filter: blur(10px);
  transform: scale(0.985);
  transition: filter 260ms ease, transform 260ms ease;
}

.project-modal[hidden] {
  display: none;
}

.project-modal {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: grid;
  place-items: center;
  padding: 1.25rem;
  opacity: 0;
  transition: opacity 240ms ease;
  pointer-events: none;
}

.project-modal.is-open {
  opacity: 1;
  pointer-events: auto;
}

.project-modal-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(1, 1, 43, 0.18);
}

.project-modal-dialog {
  position: relative;
  width: min(74vw, 560px);
  max-height: min(90vh, 820px);
  overflow: hidden;
  padding: 0.9rem;
  border: 1px solid var(--border);
  border-radius: 24px;
  background: rgba(17, 17, 78, 0.96);
  box-shadow: 0 24px 80px rgba(0, 0, 0, 0.45);
  transform: translateY(32px) scale(0.96);
  opacity: 0;
  transition: transform 260ms ease, opacity 260ms ease;
}

.project-modal-dialog.can-scroll {
  overflow-y: auto;
}

.project-modal.is-open .project-modal-dialog {
  transform: translateY(0) scale(1);
  opacity: 1;
}

.project-modal-close {
  display: none;
}

.project-modal-content {
  display: grid;
  gap: 0.85rem;
}

.project-modal-screenshot img {
  width: 100%;
  max-height: 210px;
  border-radius: 16px;
  object-fit: cover;
  display: block;
}

.project-modal-header,
.project-modal-languages,
.project-modal-description {
  display: grid;
  gap: 0.45rem;
}

.project-modal-topbar {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.project-modal-topbar h3 {
  margin-right: auto;
}

.project-modal-topbar .project-modal-links {
  gap: 0.55rem;
}

.project-modal-description p {
  max-height: none;
  overflow: visible;
}

.project-modal-dialog.can-scroll .project-modal-description p {
  overflow: visible;
}

.project-modal-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.project-modal-close-inline {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-height: 2rem;
  max-width: 3.6rem;
  padding: 0.8rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: rgb(255, 0, 0);
  color: var(--text);
  font: inherit;
  white-space: nowrap;
}

.project-modal-links a:hover,
.project-modal-close-inline:hover {
  transform: translateY(-4px);
}

.project-modal-close-inline {
  cursor: pointer;
}

.project-modal-link {
  flex: 0 0 auto;
}

.project-modal-link-live img,
.project-modal-link img {
  width: 2.5rem;
}

.project-modal h4 {
  margin: 0;
  font-size: 0.92rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
}

#project-modal-languages {
  display: flex;
  flex-wrap: wrap;
  gap: 0.65rem;
}

.project-language-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.35rem;
  padding: 0 0.95rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.92rem;
}

.stack-grid span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 2.65rem;
  padding: 0 1rem;
  border-radius: 999px;
  color: var(--text);
  font-family:'Gill Sans', 'Gill Sans MT', Calibri, 'Trebuchet MS', sans-serif;
  font-size: 0.92rem;
  font-weight: 500;
  transition: transform 180ms ease, border-color 180ms ease, background-color 180ms ease;
}

.stack-grid img{
  padding-right: 0.2rem;
  max-width: 1.5rem;
}

.stack-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.stack-grid span {
  min-height: 2.5rem;
  box-shadow: none;
}

.contact-card {
  display: grid;
  gap: 1.2rem;
  padding: 1.15rem;
  border: 1px solid var(--border);
  border-radius: 28px;
}

.contact-form {
  display: grid;
  gap: 0.9rem;
}

.contact-form-trap {
  position: absolute;
  left: -10000px;
  width: 1px;
  height: 1px;
  overflow: hidden;
  opacity: 0;
  pointer-events: none;
}

.contact-feedback {
  min-height: 1.5rem;
  font-size: 0.92rem;
}

.contact-feedback.is-error {
  color: #fc1313;
}

.contact-feedback.is-success {
  color: #23ff40;
}

.float-field {
  overflow: visible;
  position: relative;
  display: block;
  margin-bottom: 20px;
}

.float-field input {
  position: relative;
  z-index: 1;
}

.float-field input,
.float-field textarea {
  width: 100%;
  font-size: 16px;
  color: white;
  border: 1px solid #ccc;
  border-radius: 6px;
  outline: none;
  background: transparent;
  padding: 16px 12px;
  resize: vertical;
}

.float-field textarea {
  min-height: 120px;
  padding-top: 20px;
}

.float-field span {
  z-index: 3;
  position: absolute;
  left: 12px;
  font-size: 16px;
  color: #777;
  pointer-events: none;
  transition: 0.2s ease;
  background: var(--bg);
  padding: 0 6px;
}

.float-field input + span {
  top: 50%;
  transform: translateY(-50%);
}

.float-field textarea + span {
  top: 14px;
  transform: none;
}

.float-field input:focus + span,
.float-field input:not(:placeholder-shown) + span {
  top: -8px;
  font-size: 12px;
  color: rgb(0, 255, 255);
  transform: none;
}

.float-field textarea:focus + span,
.float-field textarea:not(:placeholder-shown) + span {
  top: -8px;
  font-size: 12px;
  color: rgb(0, 255, 255);
}

.float-field input:focus,
.float-field textarea:focus {
  border-color: rgb(0, 255, 255);
}

input:-webkit-autofill {
    -webkit-box-shadow: 0 0 0px 40px var(--bg) inset !important;
    -webkit-text-fill-color: #fff !important;
    caret-color: #fff;
}

input:-webkit-autofill + span {
  top: -8px;
  font-size: 12px;
  color: rgb(0, 255, 255);
  transform: none;
}

.submit-button {
  justify-self: start;
  min-height: 2.8rem;
  padding: 0 1.1rem;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  position: relative;
  overflow: hidden;
  color: #fffdf9;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.3s ease;
}

.submit-button .check{
  display:none;
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  font-size: 1.2rem;  
  color: white;
}

.submit-button:hover{
  transform: translateY(-4px);
  background-color: var(--hoover);
  content: "Submit";
}

.submit-button:hover .text {
  visibility: hidden;
}

.submit-button:hover .check {
  display: block;
}

.submit-button:disabled {
  opacity: 0.75;
  cursor: wait;
}

@keyframes blink {
  0%,
  48% {
    opacity: 1;
  }
  50%,
  100% {
    opacity: 0;
  }
}

.reveal {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 500ms ease, transform 500ms ease;
}

.reveal.is-visible {
  opacity: 1;
  transform: translateY(0);
}

@media (max-width: 720px) {
  .site-shell {
    width: min(calc(100% - 1rem), var(--max-width));
    padding-top: 1.25rem;
  }

  .page {
    gap: 2.75rem;
  }

  .hero-role {
    line-height: 1.8;
  }

  .hero-topline {
    align-items: center;
  }

  .timeline-item{  grid-template-columns: 1fr;}

  .project-modal {
    padding: 0.85rem;
  }

  .project-modal-dialog {
    width: min(92vw, 560px);
    padding: 0.85rem;
    max-height: min(90vh, 820px);
  }

  .project-card::after {
    opacity: 1;
    transform: translateY(0);
    top: auto;
    right: 0.75rem;
    bottom: 0.75rem;
  }

  .project-modal-topbar {
    align-items: flex-start;
  }

  .project-modal-topbar h3 {
    width: 100%;
    margin-right: 0;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }

  .reveal {
    opacity: 1;
    transform: none;
  }
}
