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

:root {
  --bg: #0c111c;
  --panel: #121a2b;
  --text: #e8edf7;
  --muted: #a3adc2;
  --line: #263247;
  --accent: #37d2c3;
  --accent-soft: #183b43;
  --shadow: 0 20px 42px rgba(0, 0, 0, 0.36);
  --radius-lg: 28px;
  --radius-md: 18px;
  --radius-sm: 12px;
  --transition: 0.25s ease;
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Manrope", sans-serif;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
  line-height: 1.6;
}

.background-layer {
  position: fixed;
  inset: 0;
  z-index: -1;
  background:
    radial-gradient(circle at 8% 10%, #1f2438 0, transparent 36%),
    radial-gradient(circle at 90% 88%, #15313f 0, transparent 38%),
    linear-gradient(180deg, #0c111c 0%, #070c15 100%);
}

.top-nav {
  width: min(1180px, 92%);
  margin: 1.5rem auto 0;
  padding: 1rem 1.25rem;
  border: 1px solid rgba(232, 237, 247, 0.1);
  border-radius: 16px;
  background: rgba(11, 17, 30, 0.84);
  backdrop-filter: blur(12px);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.brand {
  font-family: "Sora", sans-serif;
  font-weight: 700;
  letter-spacing: -0.02em;
}

.nav-links {
  display: flex;
  gap: 0.4rem;
}

.nav-link {
  text-decoration: none;
  color: var(--muted);
  font-weight: 700;
  font-size: 0.95rem;
  padding: 0.5rem 0.9rem;
  border-radius: 999px;
  transition: var(--transition);
}

.nav-link:hover,
.nav-link.active {
  background: var(--accent-soft);
  color: var(--accent);
}

.portfolio-shell {
  width: min(1180px, 92%);
  margin: 1.6rem auto 3rem;
  display: grid;
  grid-template-columns: 360px 1fr;
  gap: 1.2rem;
  align-items: start;
}

.profile-column {
  position: sticky;
  top: 1rem;
  height: calc(100vh - 2rem);
}

.profile-card {
  background: var(--panel);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(232, 237, 247, 0.08);
  box-shadow: var(--shadow);
  padding: 1.45rem;
  min-height: 100%;
  height: 100%;
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.profile-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.profile-photo-wrap {
  border-radius: 14px;
  overflow: hidden;
  aspect-ratio: 1 / 1;
  width: 84px;
  flex-shrink: 0;
}

.profile-photo-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.role-tag {
  display: inline-block;
  font-size: 0.76rem;
  font-weight: 700;
  color: var(--accent);
  background: var(--accent-soft);
  border-radius: 999px;
  padding: 0.32rem 0.72rem;
  margin-bottom: 0.65rem;
}

.profile-card h1 {
  font-family: "Sora", sans-serif;
  letter-spacing: -0.02em;
  font-size: 1.6rem;
  line-height: 1.2;
  margin-bottom: 0;
}

.info-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.75rem;
  margin-top: 1rem;
}

.info-item {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.6rem 0.7rem;
  background: #0f1728;
}

.info-label {
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.info-value {
  font-size: 0.9rem;
  font-weight: 700;
  margin-top: 0.15rem;
}

.profile-actions {
  display: grid;
  gap: 0.55rem;
  margin-top: auto;
  min-width: 0;
}

.github-widget {
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.8rem 0.7rem 0.7rem;
  background: #0f1728;
  width: 100%;
  min-width: 0;
  overflow: hidden;
}

.github-widget .calendar {
  width: 100%;
  min-width: 0;
}

.calendar-source {
  display: none !important;
}

.gh-activity-link {
  display: block;
  width: 100%;
  border-bottom: none;
  text-decoration: none;
}

.gh-grid-shell {
  position: relative;
  padding-top: 20px;
}

.gh-months {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 16px;
}

.gh-month-label {
  position: absolute;
  top: 0;
  font-family: "Manrope", sans-serif;
  font-size: 0.72rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: 0;
  color: var(--muted);
  transform: translateX(-6%);
  white-space: nowrap;
}

.gh-weeks {
  display: flex;
  gap: 2px;
  width: 100%;
}

.gh-week {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1 1 0;
  min-width: 0;
}

.gh-day {
  width: 100%;
  aspect-ratio: 1 / 1;
  border-radius: 2px;
  background: #223047;
}

.gh-day.level-0 {
  background: #223047;
}

.gh-day.level-1 {
  background: #2f5d86;
}

.gh-day.level-2 {
  background: #3c79aa;
}

.gh-day.level-3 {
  background: #3ea3da;
}

.gh-day.level-4 {
  background: #37d2c3;
}

.gh-summary {
  margin-top: 0.5rem;
  font-family: "Manrope", sans-serif;
  font-size: 0.84rem;
  font-weight: 600;
  line-height: 1.35;
  color: var(--muted);
}

.profile-links {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
  margin-top: 1rem;
}

.profile-links a {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 0.72rem 0.95rem;
  text-decoration: none;
  color: var(--text);
  font-weight: 700;
  font-size: 0.92rem;
  text-align: center;
  transition: var(--transition);
}

.profile-links a:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.btn {
  border: none;
  border-radius: 12px;
  padding: 0.72rem 0.95rem;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  transition: var(--transition);
  text-align: center;
}

.btn-primary {
  background: var(--accent);
  color: #03221f;
}

.btn-primary:hover {
  background: #5be7d9;
}

.content-column {
  display: grid;
  gap: 1.2rem;
}

.panel {
  background: var(--panel);
  border-radius: var(--radius-lg);
  border: 1px solid rgba(232, 237, 247, 0.08);
  box-shadow: var(--shadow);
  padding: 1.7rem;
}

.panel-head {
  margin-bottom: 1rem;
}

.panel-head-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.72rem;
  color: var(--muted);
  margin-bottom: 0.35rem;
}

.panel-head h2 {
  font-family: "Sora", sans-serif;
  letter-spacing: -0.02em;
  font-size: 1.6rem;
  line-height: 1.25;
}

.about-copy {
  color: #c8d0e1;
}

.about-copy p + p {
  margin-top: 0.8rem;
}

.project-switch {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  padding: 0.3rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #0f1728;
  margin-left: auto;
}

.project-switch-btn {
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  padding: 0.4rem 0.85rem;
  font-weight: 700;
  font-size: 0.85rem;
  cursor: pointer;
  transition: var(--transition);
}

.project-switch-btn:hover {
  color: var(--text);
}

.project-switch-btn.active {
  color: #03221f;
  background: var(--accent);
  border-color: var(--accent);
}

.project-view {
  display: none;
}

.project-view.active {
  display: block;
}

.project-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.project-card {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(260px, 0.85fr);
  align-items: center;
  gap: 1rem;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  padding: 0.95rem;
  background: #0f1728;
  transition: var(--transition);
}

.project-card:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.35);
}

.project-card img {
  order: 2;
  width: 100%;
  height: 180px;
  min-height: 180px;
  object-fit: cover;
  display: block;
  border-radius: 12px;
  border: 1px solid var(--line);
}

.project-copy {
  order: 1;
  padding: 0;
}

.project-copy h3 {
  font-size: 1.05rem;
  font-family: "Sora", sans-serif;
  margin-bottom: 0.3rem;
}

.project-copy p {
  color: var(--muted);
  font-size: 0.88rem;
  margin-bottom: 0.7rem;
}

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

.project-links a {
  font-size: 0.82rem;
  text-decoration: none;
  color: var(--accent);
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 0.25rem 0.65rem;
  font-weight: 700;
}

.project-links a:hover {
  border-color: var(--accent);
  background: var(--accent-soft);
}

.contact-layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
}

.contact-form label {
  display: block;
  margin-bottom: 0.7rem;
}

.contact-form span {
  display: block;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 0.28rem;
}

.contact-form input,
.contact-form textarea {
  width: 100%;
  border: 1px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 0.7rem 0.8rem;
  font-family: inherit;
  color: var(--text);
  background: #0f1728;
}

.contact-form input:focus,
.contact-form textarea:focus {
  outline: 2px solid rgba(15, 118, 110, 0.22);
  border-color: var(--accent);
}

.contact-message {
  min-height: 1.1rem;
  font-size: 0.85rem;
  margin-top: 0.7rem;
}

.site-footer {
  width: min(1180px, 92%);
  margin: 0 auto 2rem;
  color: var(--muted);
  text-align: center;
  font-size: 0.92rem;
}

@media (max-width: 1040px) {
  .portfolio-shell {
    grid-template-columns: 1fr;
  }

  .profile-column {
    position: static;
    height: auto;
  }

  .profile-card {
    height: auto;
    min-height: auto;
  }

  .profile-actions {
    grid-template-columns: 1fr;
  }

  .profile-links {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .panel-head-row {
    flex-direction: column;
    align-items: flex-start;
  }

  .project-switch {
    margin-left: 0;
  }

  .top-nav {
    flex-direction: column;
    align-items: stretch;
  }

  .nav-links {
    justify-content: space-between;
  }

  .profile-card {
    min-height: auto;
  }

  .profile-top {
    align-items: flex-start;
  }

  .project-card {
    grid-template-columns: 1fr;
  }

  .contact-layout {
    grid-template-columns: 1fr;
  }

  .profile-actions {
    grid-template-columns: 1fr;
  }

  .profile-links {
    grid-template-columns: 1fr;
  }

  .github-widget {
    overflow: hidden;
  }

  .panel {
    padding: 1.2rem;
    border-radius: 20px;
  }

  .panel-head h2 {
    font-size: 1.35rem;
  }
}
