@font-face {
  font-family: "Geist";
  src: url("fonts/Geist-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Geist";
  src: url("fonts/Geist-SemiBold.otf") format("opentype");
  font-weight: 600;
  font-style: normal;
  font-display: swap;
}

@font-face {
  font-family: "Gambarino";
  src: url("fonts/Gambarino-Regular.otf") format("opentype");
  font-weight: 400;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #f6f4f1;
  --text: #111;
  --muted: #6b6b6b;
  --card-radius: 26px;
  --shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

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

body {
  font-family: "Geist", sans-serif;
  font-weight: 400;
  background: var(--bg);
  color: var(--text);
  min-height: 100vh;
}

@keyframes rise-in {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.reveal {
  opacity: 0;
  transform: translateY(14px);
  animation: rise-in 0.8s ease-out forwards;
}

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

.site-header {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding: 0 0 20px;
}

.logo {
  width: 56px;
  height: 56px;
  display: grid;
  place-items: center;
  background: #f7f7f7;
  box-shadow: var(--shadow);
}

.logo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.nav-links {
  display: flex;
  gap: 32px;
  font-weight: 500;
  color: #5f5f5f;
  padding-top: 24px;
  padding-bottom: 24px;
  padding-right: 16px;
}

.nav-links a {
  transition: color 0.2s ease;
}

.nav-links a:hover {
  color: #000;
}

.split-layout {
  display: grid;
  grid-template-columns: 25% 75%;
  min-height: 100vh;
}

.panel-left {
  padding: 32px clamp(20px, 3vw, 48px);
  display: flex;
  flex-direction: column;
  gap: 28px;
  background: var(--bg);
  height: 100vh;
}

.panel-right {
  padding: 32px clamp(24px, 5vw, 60px) 60px;
  overflow-y: auto;
  height: 100vh;
}

.intro {
  padding-top: 0;
}

.intro h1 {
  font-size: clamp(2rem, 3vw, 2.8rem);
  margin-bottom: 12px;
  letter-spacing: -0.02em;
}

.intro p {
  color: var(--muted);
  line-height: 1.5;
}

.projects {
  position: relative;
}

.site-footer {
  margin-top: 28px;
  margin-right:16px;
  text-align: right;
  color: var(--muted);
  font-size: 0.9rem;
  animation-delay: 0.5s;
}

.projects-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.project-card {
  border-radius: 16px;
  padding: 20px;
  color: #f7f7f7;
  display: flex;
  flex-direction: column;
  gap: 8px;
  min-height: 440px;
  box-shadow: var(--shadow);
  transition: transform 0.35s ease, box-shadow 0.35s ease, background-size 0.35s ease;
  background-size: auto 110%;
  background-position: center;
  background-repeat: no-repeat;
  animation-delay: 0.75s;
  position: relative;
}

.project-card:nth-child(2) {
  animation-delay: 1.1s;
}

.project-card:nth-child(3) {
  animation-delay: 1.45s;
}

.project-card:nth-child(4) {
  animation-delay: 1.85s;
}

.project-card:hover {
  transform: scale(1.02);
  box-shadow: 0 26px 50px rgba(0, 0, 0, 0.12);
  background-size: auto 100%;
}

.project-card h3 {
  font-size: 1.35rem;
  opacity: 0;
  transition: opacity 0.25s ease;
  margin-bottom: -6px;
}

.project-card p {
  opacity: 0;
  transition: opacity 0.5s ease;
}

.project-card:hover h3,
.project-card:hover p,
.project-card:focus-within h3,
.project-card:focus-within p {
  opacity: 1;
}

.project-card:hover p,
.project-card:focus-within p {
  opacity: 0.6;
}

.project-link {
  color: inherit;
  text-decoration: none;
  display: flex;
  flex-direction: column;
  gap: 8px;
  height: 100%;
}

.coming-soon {
  position: absolute;
  right: 12px;
  bottom: 12px;
  background: #fff;
  color: #111;
  font-family: "Geist", sans-serif;
  font-size: 16px;
  opacity: 0;
  border-radius: 12px;
  padding: 14px 18px;
  box-shadow: 0 16px 30px rgba(0, 0, 0, 0.12);
  transform: translateY(12px);
  transition: opacity 0.4s ease, transform 0.4s ease;
  z-index: 20;
  pointer-events: none;
}

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

.span-2 {
  grid-column: span 2;
}

.hello {
  margin-top: auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 0;
  border-radius: 999px;
  border: none;
  background: transparent;
  box-shadow: none;
  font-family: "Gambarino", "Geist", sans-serif;
  font-size: 20px;
  font-weight: 600;
  cursor: pointer;
  width: 100%;
  justify-content: flex-start;
  max-width: 320px;
}

.hello:hover {
  box-shadow: none;
}

.hello-text {
  text-align: center;
}

.avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background-image: url("assets/Pat_profile.png");
  background-size: cover;
  background-position: center;
}

.hello-bubble {
  position: relative;
  background: #fff;
  border-radius: 999px;
  padding: 10px 18px;
  box-shadow: var(--shadow);
  display: inline-flex;
  align-items: center;
  margin-bottom: 4px;
  transition: transform 0.25s ease;
  animation: rise-in 0.8s ease-out both;
  animation-delay: 2.5s;
}

.hello:hover .hello-bubble {
  transform: scale(1.05);
}

.hello-bubble::after {
  content: "";
  position: absolute;
  left: 20px;
  bottom: -4px;
  width: 12px;
  height: 12px;
  background: #fff;
  transform: rotate(45deg);
  box-shadow: -6px 6px 12px rgba(0, 0, 0, 0.04);
}

@media (max-width: 960px) {
  .split-layout {
    grid-template-columns: 1fr;
  }

  .panel-left {
    border-right: none;
    height: auto;
    padding-left: clamp(20px, 3vw, 48px);
    padding-right: clamp(20px, 3vw, 48px);
  }

  .panel-right {
    overflow: visible;
    height: auto;
    display: flex;
    flex-direction: column;
    padding-left: clamp(20px, 3vw, 48px);
    padding-right: clamp(20px, 3vw, 48px);
  }

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

  .span-2 {
    grid-column: span 2;
  }

  .hello {
    margin-top: 24px;
  }

  .projects {
    order: -1;
  }

  .site-header {
    order: 1;
  }
}

@media (min-width: 961px) {
  body {
    height: 100vh;
    overflow: hidden;
  }
}

@media (max-width: 640px) {
  .site-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }

  .nav-links {
    gap: 18px;
    flex-wrap: wrap;
    justify-content: flex-end;
    width: 100%;
  }

  .projects-grid {
    grid-template-columns: 1fr;
  }

  .span-2 {
    grid-column: auto;
  }

  .project-card h3,
  .project-card p {
    opacity: 1;
  }

  .project-card p {
    opacity: 0.6;
  }

  .project-card {
    background-size: auto 100%;
  }
}
