:root {
  --text-color: #f4f4f4;
  --light-copper: #eec6a1;
  --copper: #b87333;
  --oxidized-copper: #004d4d;
  --yellow: #d4c004;
  --charcoal: #1a1a1a;
  --aged-paper: #faf1cb;
  --red: #e7541a;
  --font-head: 'Rokkitt', serif;
  --font-body: 'Inter', sans-serif;
  --theme-bg: var(--oxidized-copper);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  /* Space for bottom nav on mobile */
  background-color: var(--theme-bg);
  color: var(--text-color);
  font-family: var(--font-body);
  overflow-x: hidden;
}

section:not(.hero) {
  padding: 100px 20px;
  min-height: 100vh;
}

section h2 {
  font-family: var(--font-head);
  font-size: 4rem;
}

/* NAVIGATION */
.mobile-nav {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  padding: 1rem 2rem;
  box-sizing: border-box;
  display: flex;
  justify-content: space-between;
  align-items: center;
  z-index: 100;
  background: color-mix(in srgb, var(--theme-bg), white 15%);
  backdrop-filter: blur(5px);
}

.nav-logo {
  font-family: var(--font-head);
  font-weight: 700;
  font-size: 1.5rem;
  color: var(--light-copper);
}

.nav-links {
  display: flex;
}

.nav-links a {
  color: var(--text-color);
  text-decoration: none;
  margin-left: 20px;
  font-size: clamp(10px, 0.9rem, 24px);
  text-transform: uppercase;
  letter-spacing: 1px;
}

#decoration {
  position: absolute;
  /* Center it roughly behind the text to maximize the "overlap" effect */
  right: 5%;
  top: 50%;

  display: block;
  z-index: -1;

  /* Make it roughly the height of the screen so it frames the text */
  height: 90vh;
  width: auto;

  /* Use the Copper variable, but lower opacity so it doesn't fight the text */
  color: var(--copper);
  opacity: 0.3;

  /* Ensure clicks pass through to the text/buttons if they overlap */
  pointer-events: none;
}

#decoration path {
  stroke-linecap: round;
  stroke-linejoin: round;
}

#decoration path,
#decoration circle {
  visibility: hidden;
}

/* HERO TEXT & OUTLINE EFFECT */
.hero {
  height: 100vh;
  width: 100%;
  display: flex;
  flex-direction: row;
  justify-content: center;
  align-items: center;
}

.hero-text {
  font-family: var(--font-head);
  font-size: 20vw;
  font-weight: 800;
  line-height: 0.8;
  text-transform: uppercase;
  text-align: center;
  margin: 0;

  /* THE OUTLINE */
  color: transparent;
  -webkit-text-stroke: 1px var(--light-copper);
  position: relative;
  z-index: 10;
  writing-mode: sideways-lr;
}

#gallery {
  padding: 100px 20px 150px 20px !important;
  min-height: 100vh;
}

.artifact-grid {
  display: grid;
  /* Responsive columns that fill space automatically */
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 2rem;
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
}

.artifact {
  position: relative;
  display: flex;
  flex-direction: column;

  /* distinct items need this to prevent splitting across columns */
  break-inside: avoid;
  margin-bottom: 1rem;
  background-color: white;
  padding: 1rem;
  /* The "Matte" width */
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
  /* Subtle lift */
  transition: transform 0.3s ease;
}

.artifact img {
  width: 100%;
  height: auto;
  display: block;
  border-radius: 4px;
  filter: contrast(1.1) sepia(10%);
  /* FORCE UNIFORMITY */
  aspect-ratio: 1 / 1;
  /* Makes every image a square */
  object-fit: cover;
  /* Crops edges so image fills the square */
  object-position: center;
  /* Focuses on the middle */
}

.artifact:nth-child(even) {
  margin-top: 0;
}

#process div {
  min-height: 100vh;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}

.process-image {
  width: 100%;
  -webkit-tap-highlight-color: transparent;
  -webkit-touch-callout: none;
  user-select: none;
  touch-action: manipulation;
  /* Improves tap response */

  /* Your existing transitions */
  filter: sepia(100%);
  transition: transform 0.3s, filter 0.3s;
  will-change: transform, filter;
}

/* 2. Use a class instead of :active for the effect */
.process-image.is-pressed {
  transform: scale(1.05);
  /* Slight zoom */
  filter: sepia(0%);
  z-index: 10;
}

#about {
  position: relative;
  overflow: hidden;
}

#about p {
  font-size: 3rem;
}

#about-vine {
  position: absolute;
  left: -10%; /* Hangs slightly off-screen on the left */
  top: 0%;
  height: 100%; /* Spans the full section height */
  width: auto;
  color: #faf1cb; 
  opacity: 0.4;
  pointer-events: none;
  z-index: -1; /* Behind text but in front of background */
}

#contact .input input,
#contact .input textarea,
#contact .input input:autofill {
  font-size: 1.5rem;
  height: 4.0rem;
  width: 100%;
  background: inherit !important;
  color: var(--copper) !important;
  border: none;
}

#contact .input textarea {
  height: 6.25rem;
  resize: vertical;
}

#contact .input input:focus,
#contact .input textarea:focus {
  outline: none;
}

#contact .input {
  position: relative;
  box-sizing: border-box;
  border: 0.25rem solid #b87333;
  margin-top: 2.5rem;
  padding: 1.0rem;
  transition: 300ms;
}

#contact .input:has(textarea) {
  padding: 1.5rem;
}

#contact .input:first-child {
  margin-top: 0;
}

#contact .input:focus-within {
  background-color: white;
  border-color: white;
}

#contact .input:focus-within label,
#contact .input label:has(+ input:not(:placeholder-shown)),
#contact .input label:has(+ textarea:not(:placeholder-shown)),
#contact .input label:has(+ input:autofill) {
  top: 1rem;
  font-size: 1rem;
}

#contact .input label {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  font-size: 2.5rem;
  pointer-events: none;
  transition: 300ms;
}

#contact-submit {
  background-color: var(--copper);
  color: #d4c004;
  font-size: 1.5rem;
  height: 6.25rem;
  width: 100%;
  border: none;
  margin-top: 2.5rem;
  transition: 300ms;
}

#contact-submit:hover {
  background-color: white;
  color: var(--copper);
}

#contact-submit:disabled {
  background-color: #ccc;
  color: #666;
  pointer-events: none; /* Prevents hover effects while disabled */
}

/* TABLET/DESKTOP TWEAKS */
@media (min-width: 768px) {

  section:not(.hero) {
    padding-left: 10vw;
    padding-right: 10vw;
  }

  .hero-text {
    writing-mode: unset;
    -webkit-text-stroke: 2px var(--light-copper);
  }

  #about-vine {
    left: 5%;
  }

  #process div {
    width: fit-content;
    position: relative;
    left:0;

    margin: auto;
  }

  .process-image {
    position: relative;
    width: 25vw;
  }

  .process-image:hover {
    transform: scale(1.05);
    /* Slight zoom */
    filter: sepia(0%);
    z-index: 10;
  }

  .process-image:nth-child(1) {
    top: 25vh;
    left: 0vw;
  }

  .process-image:nth-child(2) {
    top: 0vh;
    left: 0vw;
  }

  .process-image:nth-child(3) {
    top: 30vh;
    left: 0vw;
  }
}