/* BRAVE RENDER — user patch 2026-05-08
   1) clickable contact links on home
   2) correct lightbox theme sync
   3) mobile swipe in lightbox
*/

.home-contact-link,
.home-contact-link a {
  cursor: pointer;
}

.home-contact-link a {
  color: inherit;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 12px;
  transition: opacity .25s ease;
}

.home-contact-link a:hover {
  opacity: .55;
}

body.lightbox-open .brave-lightbox-overlay {
  background-color: var(--body-bg) !important;
  color: var(--text-color) !important;
  touch-action: pan-y;
}

html[data-theme="dark"] body.lightbox-open .brave-lightbox-overlay {
  background-color: rgba(11, 11, 11, .96) !important;
}

html[data-theme="light"] body.lightbox-open .brave-lightbox-overlay {
  background-color: rgba(255, 255, 255, .96) !important;
}

body.lightbox-open .brave-lightbox-overlay .lightbox-image-shell {
  touch-action: pan-y;
}

html[data-theme="dark"] body.lightbox-open .lightbox-close-button,
html[data-theme="dark"] body.lightbox-open .brave-lightbox-prev,
html[data-theme="dark"] body.lightbox-open .brave-lightbox-next {
  color: #fff !important;
}

html[data-theme="light"] body.lightbox-open .lightbox-close-button,
html[data-theme="light"] body.lightbox-open .brave-lightbox-prev,
html[data-theme="light"] body.lightbox-open .brave-lightbox-next {
  color: #0b0b0b !important;
}

html[data-theme="light"] body.lightbox-open .lightbox-close-button {
  background: rgba(255,255,255,.42) !important;
  border-color: rgba(0,0,0,.28) !important;
}

html[data-theme="dark"] body.lightbox-open .lightbox-close-button {
  background: rgba(0,0,0,.28) !important;
  border-color: rgba(255,255,255,.32) !important;
}

body.lightbox-open .brave-lightbox-prev,
body.lightbox-open .brave-lightbox-next {
  opacity: .42 !important;
}

body.lightbox-open .brave-lightbox-prev:hover,
body.lightbox-open .brave-lightbox-next:hover {
  opacity: 1 !important;
}

@media (max-width: 767px) {
  /* Keep lightbox arrows visible on mobile */
  body.lightbox-open .brave-lightbox-prev,
  body.lightbox-open .brave-lightbox-next {
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 44px !important;
    height: 64px !important;
    padding: 8px !important;
    opacity: .5 !important;
    z-index: 999999 !important;
  }

  body.lightbox-open .brave-lightbox-prev {
    left: 4px !important;
  }

  body.lightbox-open .brave-lightbox-next {
    right: 4px !important;
  }

  body.lightbox-open .brave-lightbox-prev svg,
  body.lightbox-open .brave-lightbox-next svg {
    width: 32px !important;
    height: 32px !important;
  }

  body.lightbox-open .brave-lightbox-overlay::after {
    content: "Swipe";
    position: fixed;
    left: 50%;
    bottom: max(18px, env(safe-area-inset-bottom));
    transform: translateX(-50%);
    z-index: 999998;
    font-size: 10px;
    line-height: 1;
    letter-spacing: .12em;
    text-transform: uppercase;
    opacity: .34;
    pointer-events: none;
  }
}


/* 2026-05-08 follow-up: smoother mobile swipe + mobile text alignment */
body.lightbox-open .brave-lightbox-overlay .lightbox-image-shell {
  will-change: transform, opacity;
  transition: transform .28s cubic-bezier(.16, 1, .3, 1), opacity .28s cubic-bezier(.16, 1, .3, 1) !important;
}

body.lightbox-open .brave-lightbox-overlay.is-swiping .lightbox-image-shell {
  transition: none !important;
}

@media (max-width: 767px) {
  /* Align Selected Works text to the same left edge as the Hero text.
     Only the text header is touched — no page/container/hero sizing changes. */
  .projects-section > .reveal {
    padding-left: 0 !important;
    padding-right: 0 !important;
    align-items: flex-start !important;
    text-align: left !important;
  }

  .projects-section > .reveal > div,
  .projects-section > .reveal > a {
    margin-left: 0 !important;
    text-align: left !important;
  }

  .projects-section > .reveal h2,
  .projects-section > .reveal p,
  .projects-section > .reveal a {
    text-align: left !important;
  }
}

/* 2026-05-08 final mobile header alignment: Selected Works block + View all works link */
@media (max-width: 767px) {
  .projects-section > .reveal {
    --brave-mobile-projects-shift: 0px;
    transform: translate3d(var(--brave-mobile-projects-shift), 0, 0) !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    align-items: flex-start !important;
    text-align: left !important;
  }

  .projects-section > .reveal > div,
  .projects-section > .reveal > a,
  .projects-section > .reveal h2,
  .projects-section > .reveal p {
    margin-left: 0 !important;
    padding-left: 0 !important;
    text-align: left !important;
  }

  .projects-section > .reveal > a {
    align-self: flex-start !important;
    justify-content: flex-start !important;
  }
}
