/**
 * DESIGN ON TAP — entry gallery (/design-contest/entries/).
 *
 * Scoped under .dot-gallery-page so nothing here can reach the rest of the site.
 * Three across on desktop, two on tablet, one on phones.
 */



/* ---- hero -------------------------------------------------------------
   Same architecture as Know Before You Go: noise over black, a mono label, an
   oversized display line filled with a gradient, and a hairline-ruled foot
   carrying the facts. The gradient is gold rather than that page's blue-green —
   the structure is the house style, the colour belongs to Design on Tap.
   ----------------------------------------------------------------------- */

.dot-gallery-page { background: var(--dot-ink, #0B0B0B); color: #fff; }

.dot-gal-wrap {
	width: 88%;
	max-width: 1280px;
	margin: 0 auto;
}

.dot-gal-hero {
	position: relative;
	background: var(--dot-ink, #0B0B0B);
	overflow: hidden;
}

.dot-gal-hero .noise {
	position: absolute;
	inset: 0;
	opacity: .5;
	pointer-events: none;
}

.dot-gal-hero__inner {
	position: relative;
	z-index: 2;
	padding: clamp(60px, 9vw, 130px) 0 clamp(44px, 6vw, 80px);
}

.dot-gallery-page .dot-gal-label,
.dot-gallery-page p.dot-gal-label {
	font-family: 'silka-mono', 'Courier New', monospace;
	font-size: 11px;
	font-weight: 500;
	letter-spacing: .16em;
	text-transform: uppercase;
	color: var(--dot-gold-lit, #E2B63F);
	margin: 0;
	display: inline-block;
	text-decoration: none;
	transition: color .18s ease;
}

.dot-gallery-page a.dot-gal-label:hover { color: #fff; }

.dot-gallery-page .dot-gal-title {
	font-family: 'runaways', Helvetica, Arial, sans-serif;
	font-size: clamp(46px, 11.5vw, 168px);
	font-weight: 700;
	text-transform: uppercase;
	line-height: .88;
	letter-spacing: -.025em;
	margin: 26px 0 0;
	background: linear-gradient(90deg, #7A5F10 0%, #AC881B 32%, #E2B63F 68%, #F7E3A4 100%);
	-webkit-background-clip: text;
	background-clip: text;
	-webkit-text-fill-color: transparent;
	color: transparent;
}

.dot-gal-hero__foot {
	display: flex;
	flex-wrap: wrap;
	align-items: flex-end;
	justify-content: space-between;
	gap: 28px 60px;
	margin-top: clamp(34px, 4vw, 60px);
	padding-top: 26px;
	border-top: 1px solid rgba(226, 182, 63, .24);
}

.dot-gallery-page p.dot-gal-hero__meta {
	font-family: 'runaways', Helvetica, Arial, sans-serif;
	font-size: clamp(17px, 1.9vw, 26px);
	font-weight: 600;
	text-transform: uppercase;
	line-height: 1.2;
	color: var(--dot-gold-lit, #E2B63F);
	margin: 0;
}

/* .dot-page p sets white body text at (0,1,1) specificity, which beat a
   class-only rule here and left the paper band's lede white on white. */
.dot-gallery-page p.dot-gal-lede {
	font-size: clamp(17px, 1.5vw, 21px);
	line-height: 1.6;
	color: #b8b8b8;
	max-width: 52ch;
	margin: 0;
}

/* The preview notice sits above everything, full bleed, so it reads as chrome
   rather than as part of the page. */
.dot-gal-flag {
	background: #3a2d00;
	border-bottom: 1px solid #6b5400;
	color: #ffd75e;
	padding: 12px 24px;
	text-align: center;
	font-size: 13px;
	line-height: 1.5;
}

/* ---- grid band --------------------------------------------------------- */

.dot-gal-body { padding: clamp(48px, 6vw, 86px) 0 clamp(64px, 8vw, 110px); }

/* ---- grid ---- */

.dot-grid {
	display: grid;
	grid-template-columns: repeat(3, 1fr);
	gap: 28px;
}

@media (max-width: 1000px) {
	.dot-grid { grid-template-columns: repeat(2, 1fr); gap: 22px; }
}

@media (max-width: 640px) {
	.dot-grid { grid-template-columns: 1fr; gap: 20px; }
	.dot-gallery-page { padding: 70px 0 90px; }
}

.dot-card {
	background: #171717;
	border: 1px solid #262626;
	border-radius: 14px;
	overflow: hidden;
	display: flex;
	flex-direction: column;
	transition: border-color .18s ease, transform .18s ease;
}

.dot-card:hover { border-color: #3d3d3d; transform: translateY(-2px); }

/* The cover art is asked for at 4:3 but never enforced — the box is 4:3 and
   object-fit crops whatever arrives, so one odd-shaped upload cannot put a
   stair-step through the grid. */
.dot-card__art {
	display: block;
	width: 100%;
	aspect-ratio: 4 / 3;
	margin: 0;
	padding: 0;
	border: 0;
	background: #101010;
	cursor: zoom-in;
	position: relative;
	overflow: hidden;
}

.dot-card__art img {
	width: 100%;
	height: 100%;
	object-fit: cover;
	display: block;
	transition: transform .35s ease;
}

.dot-card:hover .dot-card__art img { transform: scale(1.03); }

/* Fallback for browsers without aspect-ratio. */
@supports not (aspect-ratio: 4 / 3) {
	.dot-card__art { height: 0; padding-bottom: 75%; }
	.dot-card__art img { position: absolute; inset: 0; }
}

.dot-card__count {
	position: absolute;
	right: 10px;
	bottom: 10px;
	background: rgba(0, 0, 0, .68);
	color: #fff;
	font-size: 12px;
	letter-spacing: .02em;
	padding: 4px 9px;
	border-radius: 999px;
	pointer-events: none;
}

.dot-card__foot {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 12px;
	padding: 14px 16px 16px;
}

.dot-card__who {
	display: flex;
	align-items: center;
	gap: 11px;
	min-width: 0;
}

.dot-card__avatar {
	width: 38px;
	height: 38px;
	border-radius: 50%;
	object-fit: cover;
	flex: 0 0 38px;
	background: #2a2a2a;
	display: flex;
	align-items: center;
	justify-content: center;
	font-size: 13px;
	font-weight: 700;
	color: #9a9a9a;
	letter-spacing: .03em;
}

.dot-card__meta { display: flex; flex-direction: column; min-width: 0; }

.dot-card__concept {
	font-weight: 600;
	font-size: 15px;
	line-height: 1.3;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.dot-card__name {
	color: #8f8f8f;
	font-size: 13px;
	line-height: 1.4;
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

/* ---- like ---- */

.dot-like {
	display: inline-flex;
	align-items: center;
	gap: 6px;
	background: transparent;
	border: 1px solid #333;
	border-radius: 999px;
	color: #9a9a9a;
	padding: 7px 13px 7px 11px;
	cursor: pointer;
	flex: 0 0 auto;
	font-size: 14px;
	line-height: 1;
	transition: color .15s ease, border-color .15s ease, background .15s ease;
}

.dot-like svg { width: 17px; height: 17px; fill: none; stroke: currentColor; stroke-width: 1.8; }

.dot-like:hover { color: #fff; border-color: #555; }

.dot-like.is-liked { color: #ff4d6d; border-color: rgba(255, 77, 109, .45); background: rgba(255, 77, 109, .1); }
.dot-like.is-liked svg { fill: currentColor; stroke: currentColor; }

.dot-like__n { font-variant-numeric: tabular-nums; }

@media (prefers-reduced-motion: reduce) {
	.dot-card, .dot-card__art img, .dot-like { transition: none; }
	.dot-card:hover { transform: none; }
	.dot-card:hover .dot-card__art img { transform: none; }
}

/* ---- lightbox ---- */

.dot-lightbox {
	position: fixed;
	inset: 0;
	z-index: 99999;
	background: rgba(0, 0, 0, .93);
	display: flex;
	align-items: center;
	justify-content: center;
	padding: 40px 64px;
	box-sizing: border-box;
}

.dot-lightbox[hidden] { display: none !important; }

.dot-lightbox__fig {
	margin: 0;
	max-width: 100%;
	max-height: 100%;
	display: flex;
	flex-direction: column;
	align-items: center;
	gap: 14px;
}

.dot-lightbox__fig img {
	max-width: 100%;
	max-height: calc(100vh - 150px);
	object-fit: contain;
	border-radius: 6px;
	display: block;
}

.dot-lightbox__cap {
	display: flex;
	align-items: baseline;
	gap: 12px;
	flex-wrap: wrap;
	justify-content: center;
	color: #cfcfcf;
	font-size: 14px;
}

.dot-lightbox__cap #dot-lb-concept { font-weight: 600; color: #fff; }
.dot-lightbox__cap #dot-lb-pos { color: #7e7e7e; font-variant-numeric: tabular-nums; }

.dot-lightbox__close,
.dot-lightbox__nav {
	position: absolute;
	background: rgba(255, 255, 255, .08);
	border: 0;
	color: #fff;
	cursor: pointer;
	border-radius: 50%;
	line-height: 1;
	transition: background .15s ease;
}

.dot-lightbox__close:hover,
.dot-lightbox__nav:hover { background: rgba(255, 255, 255, .2); }

.dot-lightbox__close { top: 20px; right: 24px; width: 44px; height: 44px; font-size: 30px; }

.dot-lightbox__nav { top: 50%; transform: translateY(-50%); width: 48px; height: 48px; font-size: 34px; }
.dot-lightbox__nav--prev { left: 16px; }
.dot-lightbox__nav--next { right: 16px; }
.dot-lightbox__nav[hidden] { display: none; }

@media (max-width: 640px) {
	.dot-lightbox { padding: 60px 12px 24px; }
	/* Arrows sit under the image on a phone so they are not covering the artwork. */
	.dot-lightbox__nav { top: auto; bottom: 18px; transform: none; width: 44px; height: 44px; }
	.dot-lightbox__nav--prev { left: 22%; }
	.dot-lightbox__nav--next { right: 22%; }
	.dot-lightbox__fig img { max-height: calc(100vh - 210px); }
}

/* ---- closing band ------------------------------------------------------
   Paper, not more black. The page was one unbroken slab; flipping the last
   band inverts it the way Know Before You Go alternates hero and sections, and
   gives the call to action somewhere to stand.
   ----------------------------------------------------------------------- */

.dot-gal-out {
	background: #fff;
	color: #0B0B0B;
	padding: clamp(64px, 8vw, 120px) 0;
}

.dot-gallery-page .dot-gal-label.ink { color: rgba(0, 0, 0, .5); }

.dot-gal-out__head {
	font-family: 'runaways', Helvetica, Arial, sans-serif;
	font-size: clamp(34px, 5.4vw, 68px);
	font-weight: 700;
	text-transform: uppercase;
	line-height: .98;
	letter-spacing: -.01em;
	color: #0B0B0B;
	margin: 22px 0 0;
}

.dot-gallery-page p.dot-gal-out__lede {
	font-size: clamp(17px, 1.5vw, 21px);
	line-height: 1.6;
	color: #3d3d3d;
	max-width: 46ch;
	margin: 20px 0 0;
}

.dot-gal-out .dot-btn-row {
	display: flex;
	flex-wrap: wrap;
	gap: 16px;
	margin-top: 40px;
}

/* A ghost button on paper needs ink borders, not the white ones it wears on
   black. */
.dot-gallery-page .dot-btn.ghost.ink {
	color: #0B0B0B !important;
	border-color: rgba(0, 0, 0, .3);
	background: transparent;
}

.dot-gallery-page .dot-btn.ghost.ink:hover {
	border-color: #0B0B0B;
	background: #0B0B0B;
	color: #fff !important;
}

@media (max-width: 640px) {
	.dot-gal-out .dot-btn-row { flex-direction: column; align-items: stretch; }
	.dot-gal-out .dot-btn-row .dot-btn { text-align: center; }
}
