* {
  box-sizing: border-box;
}

main {
  padding-left: 1rem;
  padding-right: 1rem;
  padding-bottom: 2rem;
  padding-top: 2rem;
  max-width: 1300px;
  margin: 0 auto; /* horizontally centers content*/
}

.home-main {
  padding-left: 1rem;
  padding-right: 1rem;
  margin: 0 auto;
}

body {
  margin: 0;
  font-family: sans-serif;
  background: #f7fafc;
  color: #192A51;
  font-family: 'Poppins', sans-serif;
  overflow-x: hidden;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 2rem 5rem;
  position: sticky;
  top: 0;
  z-index: 10;
}

.logo {
  width: 50px;
  display: block;
}

u {
  text-decoration-color: #d1c481;
  text-decoration-thickness: 2px;
}


/* NAVBAR */

nav a {
  margin-left: 1.5rem;
  text-decoration: none;
  color: #2c2c2c;
  transition: color 0.2s ease;
  padding: 4px;
}

nav a:hover {
  background-color: #d1c481;
  border-radius: 30px;
  padding: 4px;
  transform: scale(1.02);
}

.nav-sel {
  background-color: #d1c481;
  border-radius: 30px;
  padding: 4px;
}


/* INDEX PAGE */

body.home-body {
  background-color: #eeefe8;
  background-image: url('../assets/gradient.png');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}
.home-body h1 {
  font-size: 3rem;
}

.index-header {
  padding-top: 2rem;
  padding-bottom: 3rem;
  max-width: 1200px;
}




/* INDEX PAGE CASE STUDIES GRID */

.grid {
  display: grid;
  gap: 3rem;
  padding-top: 3rem;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
}

.card {
  overflow: hidden;
  transition: transform 0.2s ease;
  text-decoration: none;
  color: inherit;
}

.card:hover {
  transform: scale(1.02);
}

.card img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  object-position: center;
  border: solid 1px rgb(224, 224, 224);
}

.card h3 {
  padding: 1rem;
  margin: 0;
  text-align: center;
}

.card-title {
  text-align: center;
  font-weight: 500;
  padding: 1rem;
}

.card-description {
  text-align: center;
  color: #555;
}

h1, h2 {
  font-family: 'Roboto Mono', monospace;
  font-weight: 500;
  font-size: 2.2rem !important;
}

h3 {
  font-family: 'Roboto Mono', monospace;
  font-weight: normal;
}

.headshot {
  width: 300px;
  border-radius: 25px;
}



/* SKETCHBOOK PAGE */
.sketch-body {
  background-color: rgb(249, 243, 245);
}

.masonry {
  column-count: 3;
  column-gap: 2rem;
  padding-left: 2rem;
  padding-right: 2rem;
  max-width: 1300px;
  margin: 0 auto;
}
.masonry img {
  width: 100%;
  margin-bottom: 1rem;
  border-radius: 8px;
  break-inside: avoid;
}
@media (max-width: 768px) {
  .masonry {
    column-count: 2;
  }
}
@media (max-width: 480px) {
  .masonry {
    column-count: 1;
  }
}





/* PLAY PAGE */

.play-body {
  background-color: #f1f2f4;
  color: #192A51;
}

.browser-frame {
  border: 1px solid #ccc;
  border-radius: 10px;
  overflow: hidden;
  margin-bottom: 2rem;
  background: #fff;
}

.browser-bar {
  background: #eee;
  padding: 0.5rem;
  display: flex;
  gap: 0.4rem;
}

.dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  display: inline-block;
}

.red { background: #ff5f56; }
.yellow { background: #ffbd2e; }
.green { background: #27c93f; }

.browser-frame img {
  width: 100%;
  display: block;
}

.subtitle {
  display: block;
  padding-top: 2rem;
  width: 100%;
}

.designs-background {
  display: flex;
  flex-wrap: wrap;
  border-radius: 10px;
  margin-bottom: 5rem;
  padding-left: 2rem;
  padding-right: 2rem;
}

.website-background {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  color: #efc9f4;
  background-color: #1E212B;
  padding: 2rem;
  margin-left: 2rem;
  margin-right: 2rem;
}

.website-section {
  display: flex;
  gap: 3rem;
  justify-content: center;
  flex-wrap: wrap;
  margin: auto;
  padding-top: 2rem;
  padding-bottom: 2rem;
}

.website-leftcol {
  display: flex;
  flex-direction: column;
  width: 500px;
  height: 100%;
}

.title-box {
  margin: 0 auto;
  max-width: 1300px;
  text-align: center;
  margin-top: 1rem;
  margin-bottom: 3rem;
  width: fit-content;
  padding-left: 1rem;
  padding-right: 1rem;
  border-radius: 40px;
  font-size: 1.5rem;
}

.image-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2rem; 
  max-width: 1300px;
  margin: auto;
  padding-top: 1rem;
}

.item {
  text-align: center;
}

.design-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: center;
  display: block;
  border: solid 1px rgb(206, 206, 206);
}

.caption {
  margin-top: 0.5rem;
  font-size: 0.95rem;
  color: #555;
}

@media (max-width: 1024px) {
  .image-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 600px) {
  .image-grid {
    grid-template-columns: 1fr;
  }
}

/* Generic design image (non-hover ones) */
.design-img {
  width: 100%;
  height: 300px;
  object-fit: cover;
  object-position: center;
  display: block;
}

/* Only apply these styles to images inside a hover-wrapper */
.img-wrapper {
  position: relative;
  width: 100%;
  height: 300px;
  overflow: hidden;
}

.img-wrapper .design-img {
  position: absolute;
  top: 0;
  left: 0;
  transition: opacity 0.4s ease;
}

/* First image visible by default */
.img-wrapper .default-img {
  opacity: 1;
  z-index: 1;
}

/* Second image hidden by default */
.img-wrapper .hover-img {
  opacity: 0;
  z-index: 2;
}

/* On hover: swap visibility */
.img-wrapper:hover .hover-img {
  opacity: 1;
}

.img-wrapper:hover .default-img {
  opacity: 0;
}

.custom-footer {
  margin-top: 4rem;
  padding: 2rem 0;
  text-align: center;
}

.footer-content {
  position: relative;
  display: inline-block;
  height: 40px; /* match image height */
}

.footer-img,
.footer-tooltip {
  position: absolute;
  left: 50%;
  transform: translateX(-50%);
  transition: opacity 0.3s ease;
}

/* Image is visible by default */
.footer-img {
  width: 30px;
  opacity: 1;
}

/* Tooltip is hidden by default */
.footer-tooltip {
  font-family: monospace;
  font-size: 13px;
  color: #efc9f4;
  background: #1E212B;
  padding: 6px 10px;
  border-radius: 6px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
  opacity: 0;
  pointer-events: none;
  white-space: nowrap;        /* prevents shrinking */
  transform: translateX(-50%);
  left: 50%;
  position: absolute;
}


/* On hover, hide image and show tooltip */
.footer-content:hover .footer-img {
  opacity: 0;
}

.footer-content:hover .footer-tooltip {
  opacity: 1;
}


/* Starting project page template here */
.project-page {
  max-width: 1000px;
  margin: 40px auto;
  padding: 0 24px;
  font-family: 'Poppins', sans-serif;
  color: #333;
}

.hero-image img {
  width: 100%;
  border-radius: 16px;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
  margin-bottom: 40px;
}

.overview-section {
  display: flex;
  flex-wrap: wrap;
  gap: 40px;
  margin-bottom: 40px;
}

.overview-text {
  flex: 2;
}

.overview-text h1 {
  font-size: 2rem;
  margin-bottom: 0.5rem;
}

.overview-description {
  font-size: 1.1rem;
  color: #555;
}

.project-details {
  flex: 1;
  font-size: 0.95rem;
  background-color: #f8f8f8;
  padding: 16px;
  border-radius: 12px;
  line-height: 1.6;
}

.split-section {
  display: flex;
  flex-wrap: wrap;
  gap: 32px;
  margin-bottom: 40px;
}

.split-text {
  flex: 1;
  min-width: 280px;
}

.split-text h2 {
  margin-bottom: 0.5rem;
}

.process-section {
  margin-bottom: 40px;
}

.process-section h2 {
  font-size: 1.5rem;
  margin-bottom: 16px;
}

.process-steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 24px;
}

.step h3 {
  font-size: 1.1rem;
  margin-bottom: 0.25rem;
}

.final-section {
  margin-bottom: 48px;
}

.final-section img {
  width: 100%;
  border-radius: 12px;
  margin-top: 12px;
  box-shadow: 0 4px 16px rgba(0, 0, 0, 0.06);
}

.final-note {
  margin-top: 12px;
  color: #555;
  font-size: 1rem;
}

.cta-section {
  text-align: center;
  margin-bottom: 60px;
}

.project-button {
  background-color: #111;
  color: white;
  padding: 12px 24px;
  border-radius: 8px;
  font-size: 1rem;
  text-decoration: none;
  transition: background-color 0.3s;
}

.project-button:hover {
  background-color: #333;
}








/* ABOUT PAGE */
.about-body {
  color: #322520;
  background-color: #edede1;
}

.abt-content {
  align-items: center;
  max-width: 1000px;
  margin: 0 auto;
}

.intro {
  display: flex;
  gap: 3rem;
  padding-top: 2rem;
  padding-bottom: 3rem;
  flex-wrap: wrap; /* makes it responsive */
}

.headshot {
  width: 290px;
  height: 320px;
  border-radius: 25px;
  object-fit: cover;
  flex-shrink: 0;
}

.intro-text-box {
  flex: 1;
}

.intro-text-box h1 {
  font-size: 3rem;
  margin-bottom: 0.5rem;
}

.intro-text-box p {
  line-height: 1.5;
}

.button-outline {
  display: inline-block;
  padding: 0.75rem 1.5rem;
  border: 2px solid #efc9f4;
  text-decoration: none;
  font-weight: 500;
  border-radius: 30px;
  transition: all 0.3s ease;
  background-color: #efc9f4;
  color: #191970;
}

.button-outline:hover {
  background-color: #d1c481;
  border-color: #d1c481;
}