* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  font-family: 'Inter', sans-serif;
}

body {
  height: 100vh;
  display: flex;
  flex-direction: column;
  position: relative;
}

.raccoon-decoration {
  position: fixed;
  bottom: 20px;
  right: 20px;
  z-index: 10;
  cursor: pointer;
  pointer-events: none;
}

.raccoon-image {
  max-width: 250px;
  height: auto;
  display: none;
  transition: opacity 0.2s ease;
  pointer-events: auto;
}

.raccoon-image.active {
  display: block;
}

@media (min-width: 1200px) {
  .raccoon-decoration {
    right: calc(50% - 480px);
  }
}

body::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: url('assets/Background_1.jpg') no-repeat center center / cover;
  background-attachment: fixed;
  filter: saturate(0.6);
  z-index: -1;
}

/* CENTERING */
.wrapper {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* CARD */
.card {
  width: 680px;
  max-width: 92vw;
  background: #f5f5f5;
  border: 1px solid #bdbdbd;
  border-radius: 6px;
  padding: 85px 100px;   /* was smaller — this fixes proportions */
  text-align: center;
}

/* TEXT */
h1 {
  font-size: 26px;        /* was ~18–22 */
  font-weight: 400;
  color: #222;
  line-height: 1.35;      /* tighter like mockup */
  margin-bottom: 6px;
}

h1 span {
  color: #ff6a00;
  font-weight: 500;       /* was too bold before */
}

.subtitle {
  font-size: 14px;
  color: #8a8a8a;
  margin-top: 8px;
  margin-bottom: 46px;    /* IMPORTANT: more breathing room */
}

/* ICON LABELS */
.icon span {
  font-size: 12px;
}

/* DIALOG TEXT */
.dialog-body {
  padding: 14px;
  font-size: 13px;      /* was 12px */
  color: #333;
}

/* FOOTER */
footer {
  background: #2f2f2f;
  color: #bfbfbf;
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 16px;
  padding: 28px 20px 100px;
  font-size: 13px;      /* was 12px */
  position: relative;
}

.footer-credit {
  font-size: 11px;
  color: #fff;
  opacity: 0.75;
}

/* LIGHTBOX */
.lightbox {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 1000;
  cursor: pointer;
}

.lightbox.active {
  display: flex;
}

#lightbox-img {
  max-width: 90vw;
  max-height: 90vh;
  object-fit: contain;
  cursor: auto;
}

.lightbox-close {
  position: absolute;
  top: 20px;
  right: 30px;
  background: none;
  border: none;
  color: #fff;
  font-size: 40px;
  cursor: pointer;
  z-index: 1001;
  line-height: 1;
}

.lightbox-close:hover {
  color: #ccc;
}

.lightbox-nav {
  position: absolute;
  width: 100%;
  display: flex;
  justify-content: space-between;
  pointer-events: none;
}

.lightbox-prev,
.lightbox-next {
  background: rgba(0, 0, 0, 0.5);
  border: none;
  color: #fff;
  font-size: 24px;
  padding: 16px;
  cursor: pointer;
  transition: background 0.2s ease;
  pointer-events: auto;
  margin: 20px;
}

.lightbox-prev:hover,
.lightbox-next:hover {
  background: rgba(0, 0, 0, 0.8);
}


.icon-row {
  display: flex;
  justify-content: space-between;
  max-width: 420px;
  margin: 0 auto;
}

.icon {
  background: none;
  border: none;
  cursor: pointer;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  width: 80px;
  transition: transform 0.15s ease;
}

.icon svg {
  width: 42px;
  height: 42px;
  stroke-width: 1.5;
  color: #2b2b2b;
}

.icon img {
  width: 42px;
  height: 42px;
  object-fit: contain; /* Keeps aspect ratio */
  transition: transform 0.15s ease; /* Matches hover effect from before */
}

.icon:hover img {
  transform: translateY(-3px);
}


.icon span {
  font-size: 11px;
  color: #2b2b2b;
}

.icon:hover {
  transform: translateY(-3px);
}

/* DIALOG */

.dialog.active {
  display: flex;
}

.dialog {
  position: absolute;
  top: 110px;
  left: 180px;
  width: 430px;

  background: #f7f7f7;
  border: 1px solid #6f6f6f;
  border-radius: 3px;

  box-shadow: 0 5px 12px rgba(0,0,0,0.28);

  display: none;
  flex-direction: column;
}

/* HEADER */
.dialog-header {
  background: #3b3b3b;
  color: #fff;

  font-size: 13px;
  padding: 7px 12px;

  display: flex;
  justify-content: space-between;
  align-items: center;

  letter-spacing: 0.2px;
}

/* CLOSE */
.dialog-header .close {
  background: none;
  border: none;
  color: #fff;
  font-size: 14px;
  cursor: pointer;
  opacity: 0.85;
}

.dialog-header .close:hover {
  opacity: 1;
}

/* BODY */
.dialog-body {
  padding: 18px 22px;
  font-size: 14px;
  color: #2f2f2f;
  line-height: 1.55;
  overflow: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
  overflow-y: auto;
  max-height: calc(100% - 36px);
}

/* TITLE */
.dialog-body h2 {
  font-size: 16px;
  color: #ff6a00;
  margin-bottom: 12px;
}

/* PARAGRAPH 1 */
.dialog-body .p1 {
  margin-bottom: 14px;
  max-width: 100%;
}

/* PARAGRAPH 2 */
.dialog-body .p2 {
  margin-bottom: 16px;
  max-width: 100%;
}

/* EMAIL BLOCK */
.dialog-body .email {
  margin-top: 6px;
  line-height: 1.6;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.dialog-body .email span {
  color: #ff6a00;
  font-weight: 500;
}

.dialog.large {
  width: 520px;
  height: 620px;              /* fixed height */
}

.dialog-scroll {
  overflow-y: auto;
  height: calc(100% - 36px); /* minus header height */
  background: #f7f7f7;
}

.about-top {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 20px 22px;
  overflow: hidden;
  min-width: 0;
}

.avatar {
  width: 90px;
  height: 90px;
  background: #cfcfcf;
  border-radius: 50%;
  object-fit: cover;
  object-position: center;
  flex-shrink: 0;
}

.about-intro h2 {
  font-size: 20px;
  color: #ff6a00;
  margin-bottom: 4px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.about-intro p {
  font-size: 13px;
  color: #777;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.divider {
  height: 1px;
  background: #bdbdbd;
  margin: 0;
}

.about-content {
  padding: 18px 22px;
  font-size: 14px;
  color: #2f2f2f;
  line-height: 1.6;
  overflow: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.about-content p {
  margin-bottom: 10px;
}

.about-content h3 {
  margin-top: 18px;
  margin-bottom: 6px;
  font-size: 14px;
  font-weight: 600;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.about-content ul {
  padding-left: 18px;
  overflow: hidden;
}

.about-content li {
  margin-bottom: 4px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.contact-line span {
  text-decoration: underline;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.resume-section {
  padding: 18px 22px;
  overflow: hidden;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.resume-section h3 {
  font-size: 14px;
  margin-bottom: 10px;
}

.resume-box {
  width: 100%;
  height: 580px;
  border: 1px solid #bdbdbd;
  background: #eaeaea;
  overflow: hidden;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s ease;
  position: relative;
}

.resume-box:hover {
  background: #ddd;
  box-shadow: 0 2px 8px rgba(0,0,0,0.15);
  transform: scale(1.02);
}

.resume-box iframe {
  width: calc(100% + 20px);
  height: 100%;
  border: none;
  pointer-events: none;
  overflow: hidden !important;
  margin-right: -20px;
}

.resume-download {
  display: inline-block;
  margin-bottom: 10px;
  font-size: 13px;
  color: #ff6a00;
  text-decoration: none;
}

.resume-download:hover {
  text-decoration: underline;
}

.pdf-dialog {
  width: 520px;
  height: 620px;
  user-select: none;
}

.pdf-container {
  width: 100%;
  height: calc(100% - 36px);
  border: none;
  overflow: auto;
}

.pdf-container iframe {
  width: 100%;
  height: 100%;
  border: none;
  display: block;
}

.resize-handle {
  position: absolute;
  bottom: 0;
  right: 0;
  width: 20px;
  height: 20px;
  cursor: se-resize;
  background: linear-gradient(135deg, transparent 50%, #6f6f6f 50%);
  border-top: 1px solid #6f6f6f;
  border-left: 1px solid #6f6f6f;
}

.works-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 14px;
  padding: 18px;
}

.work-item {
  position: relative;
  width: 100%;
  height: 150px;
  overflow: hidden;
  border: 1px solid #cfcfcf;
  background: #ddd;
  cursor: pointer;
}

.work-item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.overlay {
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,0.6);
  color: #fff;

  display: flex;
  flex-direction: column;
  justify-content: flex-end;

  padding: 10px;

  opacity: 0;
  transition: opacity 0.2s ease;
}

.work-item:hover .overlay {
  opacity: 1;
}

.overlay h4 {
  font-size: 13px;
  margin-bottom: 2px;
}

.overlay p {
  font-size: 11px;
  opacity: 0.8;
}

.works-section {
  padding: 18px;
}

.works-section h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
  color: #2f2f2f;
}

.skills-section {
  padding: 18px;
  display: flex;
  gap: 30px;
}

.skills-column {
  flex: 1;
}

.skills-column h3 {
  font-size: 14px;
  font-weight: 600;
  margin-bottom: 12px;
  color: #2f2f2f;
}

.skill-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.skill-tag {
  display: inline-block;
  background: #ffcd8b;
  color: #000000;
  padding: 6px 12px;
  border-radius: 4px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

@media (min-width: 700px) {
  .works-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 700px) {
  body {
    min-height: 100vh;
  }

  .card {
    width: min(92vw, 520px);
    padding: 42px 24px;
  }

  h1 {
    font-size: 22px;
  }

  .subtitle {
    font-size: 13px;
    margin-bottom: 28px;
  }

  .icon-row {
    flex-wrap: wrap;
    justify-content: center;
    gap: 12px;
    max-width: none;
  }

  .icon {
    width: 68px;
  }

  .dialog,
  .dialog.large,
  .pdf-dialog,
  .project-dialog {
    width: min(92vw, 420px);
    height: auto;
    max-height: 90vh;
    left: 50% !important;
    top: 42px !important;
    transform: translateX(-50%) !important;
  }

  .dialog-scroll,
  .dialog-body,
  .project-info,
  .project-images {
    max-height: calc(90vh - 132px);
  }

  .dialog-body {
    padding: 16px 18px;
  }

  .project-content {
    flex-direction: column;
    gap: 14px;
    padding: 16px;
    height: auto;
  }

  .project-info {
    flex: none;
    width: 100%;
    padding-right: 0;
    max-height: calc(90vh - 214px);
    overflow-y: auto;
  }

  .project-images {
    flex: none;
    width: 100%;
    max-height: calc(90vh - 214px);
    overflow-y: auto;
    gap: 10px;
  }

  .project-images img {
    height: 110px;
  }

  .works-grid {
    grid-template-columns: 1fr;
    padding: 14px;
  }

  .work-item {
    height: 140px;
  }

  .skills-section {
    flex-direction: column;
    gap: 18px;
  }

  .resume-box {
    height: 260px;
  }
}

.project-dialog {
  width: 700px;
  height: 500px;
}

@media (max-width: 700px) {
  .project-dialog {
    width: min(92vw, 420px);
    height: auto;
    max-height: 92vh;
  }

  .project-info {
    max-height: calc(92vh - 220px);
  }

  .project-images {
    max-height: calc(92vh - 220px);
  }

  .project-images img {
    height: 100px;
  }
}

.project-content {
  display: flex;
  height: calc(100% - 36px);
  gap: 20px;
  padding: 20px;
  overflow: hidden;
}

.project-info {
  flex: 0 0 40%;
  display: flex;
  flex-direction: column;
  overflow-y: auto;
  padding-right: 10px;
}

.project-info h2 {
  font-size: 18px;
  color: #ff6a00;
  margin-bottom: 12px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.project-meta {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-bottom: 16px;
}

.project-meta-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.project-meta-label {
  font-size: 11px;
  color: #8b8b8b;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.project-meta-item span:last-child {
  font-size: 13px;
  color: #2f2f2f;
  line-height: 1.4;
}

.project-info p {
  font-size: 13px;
  color: #2f2f2f;
  line-height: 1.6;
  margin-bottom: 16px;
  word-wrap: break-word;
  overflow-wrap: break-word;
}

.project-button {
  display: inline-block;
  background: #ff6a00;
  color: #fff;
  padding: 8px 16px;
  border-radius: 4px;
  text-decoration: none;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
  align-self: flex-start;
}

.project-button:hover {
  background: #e55a00;
}

.project-images {
  flex: 0 0 60%;
  display: flex;
  flex-direction: column;
  gap: 12px;
  overflow-y: auto;
}

.project-images img {
  width: 100%;
  height: auto;
  border: 1px solid #bdbdbd;
  border-radius: 4px;
  object-fit: cover;
  cursor: pointer;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.project-images img:hover {
  transform: scale(1.02);
  opacity: 0.9;
}

.dialog-body a img {
  width: 42px;
  height: 42px;
  object-fit: contain;
}

.message {
  margin-bottom: 16px;
}

/* FOOTER */
footer {
  background: #2f2f2f;
  color: #bfbfbf;
  text-align: center;
  padding: 10px;
  font-size: 12px;
}