/* =============================================================
   UFB Clients Showcase — Front-end Styles
   Matches the UF+B grid design from index.html / clients.html
   ============================================================= */

/* Google Font import (matches the site's Space Grotesk) */
@import url('https://fonts.googleapis.com/css2?family=Space+Grotesk:wght@300;400;500;600;700&display=swap');

/* ------------------------------------------------------------
   Grid wrapper
   ------------------------------------------------------------ */
.ufb-clients-grid {
	display: grid;
	grid-template-columns: repeat(4, 1fr);
	border-top:   1px solid #D8D5CF;
	border-left:  1px solid #D8D5CF;
	font-family:  'Space Grotesk', -apple-system, BlinkMacSystemFont, sans-serif;
	width: 100%;
}

/* ------------------------------------------------------------
   Individual card
   ------------------------------------------------------------ */
.ufb-client-card {
	display:         flex;
	flex-direction:  column;
	align-items:     center;
	justify-content: center;
	padding:         40px 24px;
	min-height:      140px;
	border-right:    1px solid #D8D5CF;
	border-bottom:   1px solid #D8D5CF;
	text-decoration: none;
	color:           #333333;
	background:      #FFFFFF;
	transition:      background 0.25s ease, color 0.25s ease, border-color 0.25s ease;
	position:        relative;
	overflow:        hidden;
	text-align:      center;
	cursor:          default;
}

/* Cards that are anchor tags always show pointer */
a.ufb-client-card {
	cursor: pointer;
}

/* ------------------------------------------------------------
   Logo image variant
   ------------------------------------------------------------ */
.ufb-client-logo-wrap {
	display:         flex;
	align-items:     center;
	justify-content: center;
	width:           100%;
	margin-bottom:   10px;
}

.ufb-client-logo {
	max-width:   140px;
	max-height:  60px;
	width:       auto;
	height:      auto;
	object-fit:  contain;
	/* Render grayscale to match the soft monochrome aesthetic */
	filter:      grayscale(100%) opacity(0.55);
	transition:  filter 0.25s ease, opacity 0.25s ease;
	display:     block;
}

/* ------------------------------------------------------------
   Text-only variant (no logo uploaded)
   ------------------------------------------------------------ */
.ufb-client-name-only {
	display:         flex;
	align-items:     center;
	justify-content: center;
	margin-bottom:   8px;
}

.ufb-client-name-text {
	font-size:      18px;
	font-weight:    600;
	letter-spacing: 0.15em;
	text-transform: uppercase;
	color:          #B0ADA6;
	transition:     color 0.25s ease;
	line-height:    1.2;
}

/* ------------------------------------------------------------
   Label (always shown below logo or name)
   ------------------------------------------------------------ */
.ufb-client-label {
	font-size:      10px;
	font-weight:    500;
	letter-spacing: 0.18em;
	text-transform: uppercase;
	color:          #C0BAB0;
	margin-top:     4px;
	line-height:    1.4;
	transition:     color 0.25s ease;
}

/* ------------------------------------------------------------
   Home grid — subtle hover effect (lighter than clients page)
   ------------------------------------------------------------ */
.ufb-clients-home .ufb-client-card {
	cursor: default;
}

/* Thin red left-border reveal on hover */
.ufb-clients-home .ufb-client-card::before {
	content:          '';
	position:         absolute;
	left:             0;
	top:              20%;
	bottom:           20%;
	width:            2px;
	background:       #c02026;
	transform:        scaleY(0);
	transform-origin: center;
	transition:       transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	z-index:          0;
}

.ufb-clients-home .ufb-client-card > * {
	position: relative;
	z-index:  1;
}

.ufb-clients-home .ufb-client-card:hover {
	background: #fafafa;
}

.ufb-clients-home .ufb-client-card:hover::before {
	transform: scaleY(1);
}

.ufb-clients-home .ufb-client-card:hover .ufb-client-logo {
	filter: grayscale(100%) opacity(0.85);
}

.ufb-clients-home .ufb-client-card:hover .ufb-client-name-text {
	color: #888580;
}

.ufb-clients-home .ufb-client-card:hover .ufb-client-label {
	color: #c02026;
}

/* ------------------------------------------------------------
   Page grid — hover effects with brand red #c02026
   ------------------------------------------------------------ */
.ufb-clients-page .ufb-client-card.ufb-has-hover {
	cursor: pointer;
}

.ufb-clients-page .ufb-client-card.ufb-has-hover::before {
	content:    '';
	position:   absolute;
	inset:      0;
	background: #c02026;
	transform:  scaleY(0);
	transform-origin: bottom center;
	transition: transform 0.3s cubic-bezier(0.4, 0, 0.2, 1);
	z-index:    0;
}

.ufb-clients-page .ufb-client-card.ufb-has-hover > * {
	position: relative;
	z-index:  1;
}

.ufb-clients-page .ufb-client-card.ufb-has-hover:hover::before {
	transform: scaleY(1);
}

.ufb-clients-page .ufb-client-card.ufb-has-hover:hover .ufb-client-logo {
	filter:  grayscale(100%) brightness(10) opacity(1);
}

.ufb-clients-page .ufb-client-card.ufb-has-hover:hover .ufb-client-name-text {
	color: rgba(255,255,255,0.95);
}

.ufb-clients-page .ufb-client-card.ufb-has-hover:hover .ufb-client-label {
	color: rgba(255,255,255,0.75);
}

/* External link icon on hover for page grid */
.ufb-clients-page .ufb-client-card.ufb-has-hover:hover::after {
	content:     '↗';
	position:    absolute;
	top:         10px;
	right:       14px;
	font-size:   14px;
	color:       rgba(255,255,255,0.6);
	z-index:     1;
	transition:  opacity 0.2s ease;
}

/* ------------------------------------------------------------
   Responsive breakpoints
   ------------------------------------------------------------ */
@media (max-width: 1024px) {
	.ufb-clients-grid {
		grid-template-columns: repeat(3, 1fr);
	}
}

@media (max-width: 680px) {
	.ufb-clients-grid {
		grid-template-columns: repeat(2, 1fr);
	}
	.ufb-client-card {
		padding:    28px 16px;
		min-height: 100px;
	}
	.ufb-client-logo {
		max-width:  100px;
		max-height: 44px;
	}
	.ufb-client-name-text {
		font-size: 14px;
	}
}

@media (max-width: 400px) {
	.ufb-clients-grid {
		grid-template-columns: repeat(1, 1fr);
	}
}

/* ------------------------------------------------------------
   Empty state
   ------------------------------------------------------------ */
.ufb-no-clients {
	color:      #999;
	font-style: italic;
	padding:    20px 0;
}
