/* ===========================
   CUSTOM PROPERTIES
   =========================== */
:root {
  --black: #151515;
  --dark-grey: #242424;
  --green: #4ee1a0;
  --white: #ffffff;
  --grey: #d9d9d9;
  --error: #ff6f5b;
  --font: "Space Grotesk", sans-serif;
}

/* ===========================
   RESET
   =========================== */
*,
*::before,
*::after {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background-color: var(--black);
  color: var(--white);
  overflow-x: hidden;
}

ul {
  list-style: none;
}

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

img {
  display: block;
  max-width: 100%;
}

/* ===========================
   UTILITIES
   =========================== */
.container {
  width: 100%;
  max-width: 1110px;
  margin: 0 auto;
  padding: 0 16px;
}

.divider {
  height: 1px;
  background-color: var(--white);
}

/* CTA link with green underline */
.cta-link {
  display: inline-block;
  font-family: var(--font);
  font-weight: 700;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: 2.29px;
  text-transform: uppercase;
  color: var(--white);
  padding-bottom: 10px;
  border-bottom: 2px solid var(--green);
  transition: color 0.3s;
}

.cta-link:hover {
  color: var(--green);
}

/* Green underline on name */
.underline-green {
  border-bottom: 6px solid var(--green);
  padding-bottom: 2px;
}

/* ===========================
   DECORATIVE RINGS
   =========================== */
.rings {
  position: absolute;
  width: 530px;
  height: 129px;
  pointer-events: none;
  z-index: 0;
}

.rings::before,
.rings::after,
.rings .r3,
.rings .r4,
.rings .r5 {
  content: "";
  position: absolute;
  left: 0;
  width: 530px;
  border: 1px solid var(--white);
  border-radius: 50%;
  opacity: 0.25;
}

.rings::before {
  height: 80px;
  top: 0;
}

.rings::after {
  height: 80px;
  top: 12px;
}

/* Using box-shadow for multiple rings */
.rings {
  background: none;
}

.rings::before {
  height: 80px;
  top: 0;
  box-shadow:
    0 0 0 0 transparent,
    0 12px 0 0 transparent;
}

/* Simplified: use a single pseudo with multiple box-shadows */
.rings::before {
  width: 530px;
  height: 80px;
  border: 1px solid rgba(255, 255, 255, 0.25);
  border-radius: 50%;
  box-shadow:
    0 12px 0 -1px transparent,
    0 12px 0 0 rgba(255, 255, 255, 0.25),
    0 25px 0 -1px transparent,
    0 25px 0 0 rgba(255, 255, 255, 0.25),
    0 37px 0 -1px transparent,
    0 37px 0 0 rgba(255, 255, 255, 0.25),
    0 49px 0 -1px transparent,
    0 49px 0 0 rgba(255, 255, 255, 0.25);
}

.rings::after {
  display: none;
}

.rings--hero-left {
  left: -100px;
  top: 133px;
}

.rings--skills-right {
  right: -265px;
  bottom: 0;
  left: auto;
}

.rings--contact-left {
  left: -205px;
  bottom: -50px;
}

.circle-deco {
  position: absolute;
  width: 129px;
  height: 129px;
  border: 1px solid var(--white);
  border-radius: 50%;
  opacity: 0.25;
  z-index: 2;
}

/* ===========================
   SOCIAL NAV
   =========================== */
.social-nav {
  display: flex;
  align-items: center;
  gap: 32px;
}

.social-link {
  color: var(--white);
  transition: color 0.3s;
  display: flex;
}

.social-link:hover {
  color: var(--green);
}

.social-link svg {
  width: 24px;
  height: 24px;
}

/* ===========================
   HEADER
   =========================== */
.header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 39px;
  padding-bottom: 40px;
  position: relative;
  z-index: 2;
}

.logo {
  font-weight: 700;
  font-size: 24px;
  line-height: 32px;
  letter-spacing: -0.33px;
  color: var(--white);
  transition: color 0.3s;
}

.logo:hover {
  color: var(--green);
}

/* ===========================
   HERO SECTION
   =========================== */
.hero-section {
  position: relative;
  overflow: hidden;
}

.hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  position: relative;
  padding-bottom: 80px;
}

.hero-photo-wrap {
  width: 174px;
  margin-top: 30px;
  margin-bottom: 40px;
  position: relative;
  z-index: 1;
}

.hero-photo {
  width: 100%;
  height: auto;
  /* filter: grayscale(100%); */
  position: relative;
  z-index: 1;
}

/* Dark grey panel behind hero photo */
.hero-bg-panel {
  display: none;
}

/* ::before pseudo for dark panel - only shown at tablet+ via media query */

.hero-text {
  position: relative;
  z-index: 2;
}

.hero-title {
  font-weight: 700;
  font-size: 40px;
  line-height: 48px;
  letter-spacing: -1.14px;
  margin-bottom: 24px;
}

.hero-desc {
  font-weight: 500;
  font-size: 16px;
  line-height: 26px;
  color: var(--grey);
  max-width: 445px;
  margin: 0 auto 24px;
}

.circle-deco {
  right: -65px;
  top: 390px;
}

/* ===========================
   SKILLS
   =========================== */
.skills-section {
  position: relative;
  padding: 40px 0;
  overflow: hidden;
}

.skills-grid {
  display: flex;
  flex-wrap: wrap;
  padding: 40px 0;
  text-align: center;
}

.skill-item {
  width: 100%;
  padding: 16px 0;
}

.skill-name {
  font-weight: 700;
  font-size: 32px;
  line-height: 40px;
  letter-spacing: -1px;
  margin-bottom: 2px;
}

.skill-exp {
  font-weight: 500;
  font-size: 16px;
  line-height: 26px;
  color: var(--grey);
}

/* ===========================
   PROJECTS
   =========================== */
.projects-section {
  padding: 80px 0;
}

.projects-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 40px;
}

.section-title {
  font-weight: 700;
  font-size: 40px;
  line-height: 48px;
  letter-spacing: -1.14px;
}

.projects-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
}

.project-card {
  width: 100%;
}

.project-img-wrap {
  position: relative;
  overflow: hidden;
  margin-bottom: 20px;
}

.project-img-wrap img {
  width: 100%;
  height: auto;
  display: block;
}

/* ===========================
   CAROUSEL
   =========================== */
.carousel {
  position: relative;
}

.carousel-img {
  width: 100%;
  height: auto;
  display: block;
  position: absolute;
  top: 0;
  left: 0;
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}

.carousel-img.active {
  position: relative;
  opacity: 1;
  pointer-events: auto;
}

.carousel-arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background: rgba(0, 0, 0, 0.55);
  border: none;
  color: var(--white);
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  z-index: 6;
  border-radius: 50%;
  transition: background 0.2s;
}

.carousel-arrow:hover {
  background: rgba(0, 0, 0, 0.8);
}

.carousel-arrow--left {
  left: 12px;
}

.carousel-arrow--right {
  right: 12px;
}

@media (min-width: 1110px) {
  .carousel-arrow {
    display: none;
  }
  .project-card:hover .carousel-arrow {
    display: flex;
  }
}

/* Desktop hover overlay - hidden by default, shown on hover for desktop */
.project-overlay {
  position: absolute;
  inset: 0;
  background-color: rgba(0, 0, 0, 0.75);
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 48px;
  transition: opacity 0.3s;
}

.project-name {
  font-weight: 700;
  font-size: 24px;
  line-height: 32px;
  text-transform: uppercase;
  margin-bottom: 7px;
}

.project-tech {
  display: flex;
  gap: 18px;
  font-weight: 500;
  font-size: 18px;
  line-height: 28px;
  color: var(--grey);
  text-transform: uppercase;
  margin-bottom: 20px;
}

/* Mobile/tablet: show links below the card */
.project-links {
  display: flex;
  gap: 30px;
}

/* ===========================
   CONTACT + BOTTOM SECTION
   =========================== */
.bottom-section {
  background-color: var(--dark-grey);
}

.contact {
  position: relative;
  padding: 60px 0;
  overflow: hidden;
}

.contact-inner {
  display: flex;
  flex-direction: column;
  gap: 50px;
}

.contact-info {
  text-align: center;
}

.contact-info .section-title {
  margin-bottom: 20px;
}

.contact-info p {
  font-weight: 500;
  font-size: 16px;
  line-height: 26px;
  color: var(--grey);
}

/* Form */
.contact-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.field-wrap {
  position: relative;
}

.field-wrap input,
.field-wrap textarea {
  width: 100%;
  background: transparent;
  border: none;
  border-bottom: 1px solid var(--white);
  padding: 0 24px 16px;
  font-family: var(--font);
  font-weight: 500;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: -0.22px;
  color: var(--white);
  text-transform: uppercase;
  outline: none;
  transition: border-color 0.3s;
}

.field-wrap input::placeholder,
.field-wrap textarea::placeholder {
  color: rgba(255, 255, 255, 0.5);
  text-transform: uppercase;
}

.field-wrap input:focus,
.field-wrap textarea:focus {
  border-bottom-color: var(--green);
}

.field-wrap textarea {
  resize: vertical;
  min-height: 107px;
}

/* Error state */
.field-wrap.has-error input,
.field-wrap.has-error textarea {
  border-bottom-color: var(--error);
}

.field-error {
  display: block;
  text-align: right;
  font-weight: 500;
  font-size: 12px;
  line-height: 16px;
  letter-spacing: -0.17px;
  color: var(--error);
  margin-top: 5px;
}

.field-error[hidden] {
  display: none;
}

.error-icon {
  position: absolute;
  right: 0;
  top: 0;
}

.error-icon[hidden] {
  display: none;
}

.form-submit {
  display: flex;
  justify-content: flex-end;
}

.form-status {
  margin: 16px 0 0;
  font-size: 16px;
  line-height: 26px;
  text-align: right;
}
.form-status.is-success {
  color: var(--green);
}
.form-status.is-error {
  color: var(--error);
}
.form-status[hidden] {
  display: none;
}

.cta-btn {
  background: transparent;
  border: none;
  cursor: pointer;
  font-family: var(--font);
  font-weight: 700;
  font-size: 16px;
  line-height: 26px;
  letter-spacing: 2.29px;
  color: var(--white);
  padding: 0 0 10px;
  border-bottom: 2px solid var(--green);
  transition: color 0.3s;
}

.cta-btn:hover {
  color: var(--green);
}

/* ===========================
   FOOTER
   =========================== */
.footer {
  padding: 40px 0 60px;
}

.footer-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 20px;
  padding-top: 40px;
}

.footer .logo {
  font-size: 24px;
}

/* ===========================================================
   TABLET (768px+)
   =========================================================== */
@media (min-width: 768px) {
  .container {
    padding: 0 30px;
  }

  /* Header */
  .header {
    padding-top: 30px;
  }

  .logo {
    font-size: 32px;
    line-height: 32px;
    letter-spacing: -0.44px;
  }

  /* Hero */
  .hero {
    position: relative;
    text-align: left;
    align-items: flex-start;
    padding-bottom: 60px;
  }

  .hero-photo-wrap {
    position: absolute;
    margin-top: 80px;
    right: 0;
    top: 0;
    width: 322px;
    z-index: 1;
    overflow: visible;
  }

  .hero-photo-wrap::before {
    content: "";
    position: absolute;
    top: -200px;
    left: 0;
    right: 0;
    bottom: 0;
    /* background-color: var(--dark-grey); */
    z-index: 0;
  }

  .hero-text {
    max-width: 62%;
  }

  .hero-title {
    font-size: 72px;
    line-height: 72px;
    letter-spacing: -2.05px;
  }

  .hero-desc {
    margin: 0 0 34px;
    font-size: 18px;
    line-height: 28px;
  }

  .circle-deco {
    right: -65px;
    top: 370px;
  }

  .rings--hero-left {
    left: -265px;
    top: 86px;
  }

  /* Skills */
  .skills-section {
    padding: 52px 0;
  }

  .skills-grid {
    text-align: left;
  }

  .skill-item {
    width: 50%;
    padding: 24px 0;
  }

  .skill-name {
    font-size: 48px;
    line-height: 56px;
    letter-spacing: -1.5px;
  }

  .skill-exp {
    font-size: 18px;
    line-height: 28px;
  }

  /* Projects */
  .projects-section {
    padding: 100px 0 80px;
  }

  .section-title {
    font-size: 72px;
    line-height: 72px;
    letter-spacing: -2.05px;
  }

  .projects-grid {
    gap: 30px 24px;
  }

  .project-card {
    width: calc(50% - 12px);
  }

  /* On tablet: show links, hide overlay */
  .project-links {
    display: flex;
  }

  /* Contact */
  .contact {
    padding: 60px 0;
  }

  .contact-info {
    text-align: center;
    max-width: 445px;
    margin: 0 auto;
  }

  .contact-info p {
    font-size: 18px;
    line-height: 28px;
  }

  /* Footer */
  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
  }
}

/* ===========================================================
   DESKTOP (1440px+)
   =========================================================== */
@media (min-width: 1110px) {
  .container {
    padding: 0;
  }

  /* Header */
  .header {
    padding-top: 39px;
  }

  /* Hero */
  .hero {
    padding-bottom: 100px;
    min-height: 620px;
  }

  .hero-photo-wrap {
    width: 445px;
    top: 0;
    right: 0;
  }

  .hero-title {
    font-size: 80px;
    line-height: 88px;
    letter-spacing: -2.5px;
  }

  .hero-text {
    max-width: 706px;
    padding-top: 60px;
  }

  .underline-green {
    border-bottom-width: 6px;
  }

  .circle-deco {
    right: 380px;
    top: 521px;
  }

  .rings--hero-left {
    left: -100px;
    top: 133px;
  }

  /* Skills */
  .skills-section {
    padding: 72px 0;
  }

  .skill-item {
    width: 33.333%;
  }

  .skills-grid {
    padding: 58px 0;
  }

  .rings--skills-right {
    right: -265px;
    bottom: -30px;
  }

  /* Projects */
  .projects-section {
    padding: 140px 0 100px;
  }

  .section-title {
    font-size: 88px;
    line-height: 88px;
    letter-spacing: -2.5px;
  }

  .projects-header {
    margin-bottom: 64px;
  }

  .projects-grid {
    gap: 40px 30px;
  }

  .project-card {
    width: calc(50% - 15px);
  }

  /* Desktop: show overlay on hover, hide links below */
  .project-overlay {
    display: flex;
    opacity: 0;
  }

  .project-card:hover .project-overlay {
    opacity: 1;
  }

  .project-links {
    display: none;
  }

  /* Contact */
  .contact {
    padding: 84px 0;
  }

  .contact-inner {
    flex-direction: row;
    gap: 0;
    justify-content: space-between;
    align-items: flex-start;
  }

  .contact-info {
    text-align: left;
    max-width: 445px;
    flex-shrink: 0;
  }

  .contact-info .section-title {
    margin-bottom: 36px;
  }

  .contact-form {
    width: 445px;
    flex-shrink: 0;
  }

  .rings--contact-left {
    left: -205px;
    bottom: 100px;
  }

  /* Footer */
  .footer {
    padding: 47px 0 92px;
  }

  .footer-inner {
    flex-direction: row;
    justify-content: space-between;
    padding-top: 48px;
  }

  .footer .logo {
    font-size: 32px;
  }
}

/* ===========================================================
   MOBILE SPECIFIC (below 768px)
   =========================================================== */
@media (max-width: 767px) {
  .header {
    flex-direction: column;
    gap: 20px;
    padding-top: 20px;
  }

  .social-nav {
    gap: 26px;
  }

  .logo {
    font-size: 24px;
  }

  .section-title {
    font-size: 40px;
    line-height: 40px;
    letter-spacing: -1.14px;
  }

  .projects-header .cta-link {
    font-size: 14px;
  }
}
