/* Local portfolio extension. All brand tokens come from atelier.css. */
.tg-page {overflow-wrap: anywhere}
.tg-page .price-group h3 span {white-space: normal}
.tattoo-hero.tg-hero {position: relative; isolation: isolate; padding-block: clamp(1.8rem, 3.4vw, 3.4rem); background: var(--bg)}
.tg-hero-photo {position: absolute; inset: 0; z-index: -1; overflow: hidden; pointer-events: none}
.tg-hero-photo img {position: absolute; inset-block: 0; right: max(0px, calc((100% - 102rem) / 2)); width: min(76%, 80rem); height: 100%; object-fit: cover; object-position: right bottom; mask-image: linear-gradient(to right, transparent, #0008 36%, black 66%, black 87%, transparent)}
.tg-hero-photo::after {content: ''; position: absolute; inset: 0; background: linear-gradient(to bottom, var(--bg), transparent 10%, transparent 86%, var(--bg))}
.tg-intro {position: relative}
.tg-intro > div {max-width: 41rem}
.tg-hero .eyebrow {text-transform: none; letter-spacing: .07em}
.tg-hero h1 {font-size: clamp(2.75rem, 5.5vw, 5.2rem); margin: 0 0 1rem}
.tg-hero .lede {max-width: 48ch}
.tg-hero .actions {gap: .55rem .8rem; margin-top: 1rem}
.tg-hero .jump-nav {margin-top: .55rem}
.tg-hero .rate-glance {margin-top: .8rem}
.tg-section {border-top: 1px solid var(--rule)}
.tg-section-intro {max-width: 54rem}
.tg-grid {display: grid; grid-template-columns: minmax(0, 400px); justify-content: center; gap: 2.5rem 24px}
.tg-card {min-width: 0; display: flex; flex-direction: column}
.tg-photo-link {display: block; text-decoration: none; color: var(--gold-bright)}
.tg-photo {display: flex; align-items: center; justify-content: center; width: 100%; aspect-ratio: 4/5; border: 1px solid #62503a; background: #211b16; overflow: hidden}
.tg-photo img {display: block; width: 100%; height: 100%; object-fit: contain}
.tg-photo picture {display: block; width: 100%; height: 100%}
.tg-photo picture[hidden] {display: none}
.tg-card-image-error {padding: 1rem; color: var(--ink); font-size: .9rem; line-height: 1.6}
.tg-card-image-error[hidden], .tg-image-error[hidden], .tg-view-controls[hidden] {display: none}
.tg-view {display: flex; justify-content: space-between; align-items: center; min-height: 32px; padding-block: .3rem; font-size: .78rem; letter-spacing: .03em}
.tg-photo-link:hover .tg-photo {border-color: var(--gold)}
.tg-photo-link:hover .tg-view {text-decoration: underline; text-underline-offset: .24em}
.tg-copy {display: flex; flex: 1; flex-direction: column; padding-top: .45rem; border-top: 1px solid var(--rule)}
.tg-meta {font-size: .78rem; color: var(--dim); line-height: 1.5; letter-spacing: .035em}
.tg-copy h3 {margin-top: .4rem; font-size: clamp(1.85rem, 2.5vw, 2.35rem); line-height: 1.08; overflow-wrap: anywhere}
.tg-description {color: var(--muted); font-size: .94rem; line-height: 1.65; margin-top: .7rem}
.tg-extra-views {display: flex; flex-direction: column; align-items: flex-start; margin-top: .65rem}
.tg-extra-views a {display: inline-flex; align-items: center; gap: .5rem; min-height: 44px; max-width: 100%; padding-block: .35rem; color: var(--gold-bright); font-size: .85rem; line-height: 1.5; text-underline-offset: .2em}
.tg-invitation {margin-top: clamp(2rem, 4vw, 3.4rem); padding-top: 1.4rem; border-top: 1px solid var(--gold-line)}
.tg-invitation > p {color: var(--muted); max-width: 60ch}
.tg-invitation > .note {margin-top: .7rem}

html.tg-locked {overflow: hidden}
.tg-dialog:not([open]) {display: none}
.tg-dialog {padding: 0; margin: auto; width: min(68rem, calc(100% - 2rem)); max-width: none; max-height: calc(100vh - 2rem); max-height: calc(100dvh - 2rem); overflow-y: auto; overscroll-behavior: contain; background: var(--raised); color: var(--ink); border: 1px solid var(--gold-line); border-radius: 2px}
.tg-dialog::backdrop {background: rgb(6 5 4 / 88%)}
.tg-dialog-bar {position: sticky; top: 0; z-index: 1; display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: .2rem 1rem; padding: .45rem 1rem; background: var(--raised); border-bottom: 1px solid var(--rule)}
.tg-dialog-bar > span {font-size: .74rem; color: var(--dim); letter-spacing: .045em}
.tg-close {display: inline-flex; gap: .7rem; align-items: center; justify-content: center; min-height: 46px; padding: .5rem .6rem; margin-left: auto; background: transparent; color: var(--gold-bright); border: 1px solid transparent; border-radius: 2px; font-size: .9rem; font-weight: 600}
.tg-close:hover {border-color: var(--gold-line); background: var(--well)}
.tg-close > span {font-size: 1.4rem; font-weight: 400}
.tg-dialog-body {display: grid; grid-template-columns: minmax(0, 1.12fr) minmax(0, .88fr); gap: 0; align-items: center}
.tg-detail-photo {min-width: 0; padding: 1rem; background: #211b16}
.tg-detail-stage {position: relative; height: min(70vh, 47rem); height: min(70dvh, 47rem)}
.tg-detail-stage picture {display: block; width: 100%; height: 100%}
.tg-detail-photo img {display: block; width: 100%; height: 100%; object-fit: contain}
.tg-detail-photo img[hidden] {display: none}
.tg-view-caption {margin-top: .65rem; color: var(--muted); font-size: .8rem; line-height: 1.5}
.tg-view-controls {display: flex; flex-wrap: wrap; gap: .5rem; margin-top: .65rem}
.tg-view-controls button {min-height: 44px; max-width: 100%; padding: .5rem .65rem; background: transparent; color: var(--gold-bright); border: 1px solid var(--gold-line); border-radius: 2px; font: inherit; font-size: .8rem; line-height: 1.5; overflow-wrap: anywhere; scroll-margin-block-start: 8rem}
.tg-view-controls button[aria-pressed="true"] {background: var(--well); border-color: var(--gold-bright); text-decoration: underline; text-underline-offset: .2em}
.tg-detail-copy {min-width: 0; padding: clamp(1rem, 3vw, 2.3rem)}
.tg-detail-copy h2 {font-size: clamp(2rem, 4vw, 3.4rem); margin-top: .55rem; overflow-wrap: anywhere}
.tg-detail-copy .note {margin-top: 1.1rem}
.tg-original {margin-top: .8rem}
.tg-dialog :focus-visible {outline: 3px solid #f4d48a; outline-offset: 4px}
.tg-detail-copy h2:focus {outline: none}
.tg-detail-copy h2:focus-visible {outline: 3px solid #f4d48a; outline-offset: 4px}
.tg-image-error {position: absolute; inset: 0; display: grid; place-content: center; color: var(--ink); padding: 1rem; line-height: 1.6}

@media (min-width: 46rem) {
  .tg-grid {grid-template-columns: repeat(2, minmax(0, 400px))}
}
@media (min-width: 62rem) {
  .tg-grid {grid-template-columns: repeat(3, minmax(0, 400px))}
}
@media (max-width: 46rem) {
  .tg-hero-photo img {right: 0; width: 100%; height: min(100%, 21rem); object-position: right bottom; mask-image: linear-gradient(to right, transparent, #0009 26%, black 72%, transparent)}
  .tg-hero-photo::after {height: min(100%, 21rem); background: linear-gradient(to right, rgb(16 15 14 / 46%), rgb(16 15 14 / 20%) 85%), linear-gradient(to bottom, var(--bg), transparent 10%, transparent 58%, var(--bg))}
  .tg-hero h1 {max-width: 12ch}
  .tg-hero .lede {font-size: 1rem; line-height: 1.6}
  .tg-hero .actions {align-items: flex-start}
  .tg-hero .rate-glance {font-size: .9rem}
  .tg-dialog {width: calc(100% - 1rem); max-height: calc(100vh - 1rem); max-height: calc(100dvh - 1rem)}
  .tg-dialog-body {grid-template-columns: minmax(0, 1fr)}
  .tg-detail-photo {padding: .65rem}
  .tg-detail-stage {height: 56vh; height: 56dvh}
  .tg-dialog-bar {padding-inline: .65rem}
  .tg-dialog-bar > span {font-size: .67rem}
}
/* Keep whole CTA words readable when text is enlarged on a narrow screen. */
@media (max-width: 24rem) {
  .tg-page .btn, .tg-dialog .btn {display: block; padding-inline: .5rem}
  .tg-dialog .tg-detail-copy {padding-inline: .65rem}
}
@media (forced-colors: active) {
  .tg-hero-photo {display: none}
  .tg-photo, .tg-dialog, .tg-dialog-bar, .tg-close {border-color: CanvasText}
  .tg-dialog :focus-visible {outline-color: Highlight}
}
@media print {
  .tg-hero-photo, .tg-dialog, .tg-view {display: none !important}
  .tg-card {break-inside: avoid}
}
