/* Layout Wrapper */
.approvals_wrapper
{
	display: flex;
	flex-direction: column;
	/* gap: 1rem; */
	max-width: 1400px;
	margin: 0 auto;
	padding: 40px;
}

.badge.heading
{
	display: flex;
	align-self: center;
	align-content: center;
	flex-wrap: wrap;

	margin-bottom: 40px;
	/* Same as wrapper padding above */
	border: 6px solid var(--primary-orange);
	border-radius: var(--std-border-radius);
	box-shadow: 0px 8px 20px 10px rgba(0, 0, 0, 0.5);

	font-size: clamp(1rem, 6vw, 5rem);
	font-weight: 700;
	letter-spacing: 8px;

	transition: all .3s ease;
	animation: letters_expand 1.3s .3s ease forwards;
}

@keyframes letters_expand
{
	100%
	{
		letter-spacing: 24px;
		/* margin-right: -24px; */
	}
}

.badge.heading .text
{
	padding: 15px 30x;
	margin-right: -8px;

	animation: margin_move 1.3s .3s ease forwards;
}

@keyframes margin_move
{
	100%
	{
		margin-right: -24px;
	}
}

.approvals_section
{
	border-radius: var(--std-border-radius);
}

/* --- Right: Command Deck --- */
.control_bar
{
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-family: "Barlow", sans-serif;
	font-weight: 800;
	font-size: 1.1rem;
}

.deck_tabs
{
	display: flex;
	/* gap: 2px; */
	/* margin-bottom: 20px; */
}

.tab_btn
{
	background: var(--element-bg-primary);
	border: var(--element-border-secondary);
	border-bottom: 2px solid transparent;
	color: #aaa;
	padding: 10px 20px;
	cursor: pointer;
	font-family: "Barlow", sans-serif;
	font-weight: 800;
	font-size: inherit;
	/* clip-path: polygon(10px 0, 100% 0, 100% 100%, 0 100%); */
	/* box-shadow: var(--secondary-shadow); */
	transition: all 0.2s ease;
}

.tab_btn:hover
{
	color: var(--gray-text);
	border-bottom-color: rgb(50, 50, 50);
}

.tab_btn:first-of-type
{
	border-top-left-radius: var(--std-border-radius);
}

.tab_btn:last-of-type
{
	border-top-right-radius: var(--std-border-radius);
}

.tab_btn.active
{
	background: var(--element-bg-secondary);
	border-bottom-color: white;
	color: white;
	z-index: 5;
}

/* --- Feed & Toolbar --- */

.feed_toolbar
{
	display: flex;
	flex-direction: column;
	/* justify-content: center; */
	align-items: center;
	margin-bottom: 20px;
	background: var(--element-bg-primary);
	padding: 15px;
	border-radius: var(--std-border-radius);
	border-top-left-radius: 0;
	/* border-bottom: 4px solid rgba(26, 26, 26, 0.5); */
	box-shadow: var(--primary-shadow);
}

.result_count
{
	color: var(--primary-orange);
	font-size: 1.5rem;
	text-transform: uppercase;
	font-weight: bold;
}

.celebration_gif
{
	justify-self: center;
	align-self: center;
	display: flex;
	align-items: center;
	flex: 1;
	padding: 40px;
	/* width: 8rem; */
	border-radius: var(--std-border-radius)
}

/* --- The Grid --- */
.asset_grid
{
	display: grid;
	/* Auto-fit magic: cards will resize but never get smaller than 250px */
	grid-template-columns: repeat(auto-fill, minmax(250px, .8fr));
	gap: 20px;
	background: var(--element-bg-primary);
	border-radius: var(--std-border-radius);
	backdrop-filter: blur(var(--std-blur-val));
	padding: 10px;
	box-shadow: var(--primary-shadow);
}

.asset_card
{
	/* background: var(--element-bg-secondary); */
	/* border: var(--element-border-primary); */
	border-radius: var(--std-border-radius);
	overflow: hidden;
	/* remove the old generic fade animation and start cards hidden */
	animation: none;
	opacity: 0;
	transform: translateY(0) scale(1);
	box-shadow: var(--secondary-shadow);
	transition: all 300ms ease, opacity 480ms cubic-bezier(.2, .9, .3, 1);
}

.asset_card.update
{
	min-height: 5rem;
}

/* New staggered "pop & rise" animation.
   Uses --delay (e.g. 0.08s, 0.16s...) to stagger each card. */
.asset_card.animate-in
{
	/* Have to have the fade as a separate animation so we can  */
	animation: card_pop 480ms cubic-bezier(.2, .9, .3, 1) var(--delay, 0s), fade_in 480ms cubic-bezier(.2, .9, .3, 1) var(--delay, 0s) both;
	opacity: 1;
}

/* Slight secondary hover polish (keeps existing behavior) */
.asset_card:hover
{
	transform: translateY(-5px) scale(1.02);
	/* background-color: var(--element-bg-secondary); */
	box-shadow: 0 6px 12px rgba(0, 0, 0, 0.2);
	border-color: var(--off-orange);
}

/* Keyframes for pop/rise */
@keyframes card_pop
{
	0%
	{
		transform: translateY(18px) scale(0.8);
		box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
	}

	30%
	{
		transform: translateY(-6px);
		box-shadow: 0 18px 36px rgba(0, 0, 0, 0.5);
	}

	100%
	{
		transform: translateY(0) scale(1);
		box-shadow: var(--secondary-shadow);
	}
}

@keyframes fade_in
{
	0%
	{
		opacity: 0;
	}

	30%
	{
		opacity: 1;
	}
}

.card_thumb
{
	display: block;
	position: relative;
	width: 100%;
	aspect-ratio: 1/1;
	overflow: hidden;
	cursor: pointer;
}

.card_thumb img
{
	width: 100%;
	height: 100%;
	object-fit: cover;
	cursor: pointer;
}

.card_thumb.update
{
	aspect-ratio: 2/1;
}

.card_thumb.update img
{
	height: 50%;
}

.card_type_badge
{
	position: absolute;
	top: 10px;
	left: 10px;
	background: rgba(0, 0, 0, 0.4);
	color: var(--primary-orange);
	padding: 4px 8px;
	font-size: .8rem;
	font-weight: bold;
	border-radius: var(--std-border-radius);
	border: 1px solid var(--primary-orange);
	backdrop-filter: blur(var(--std-blur-val));
}

.card_body
{
	display: flex;
	flex-direction: column;
	gap: 15px;
	padding: 15px;
	background-color: var(--secondary-orange);
}

.asset_card:hover .card_body
{
	border-color: var(--element-bg-primary);
}

.card_body_header
{
	display: flex;
	justify-content: space-between;
}

.card_title
{
	margin-bottom: 10px;
	font-size: 1rem;
	font-weight: normal;
	letter-spacing: 0;
	color: white;
	/* Truncate text if too long */
	white-space: nowrap;
	overflow: hidden;
	text-overflow: ellipsis;
}

.card_title.update
{
	font-size: 1.2rem;
	margin: 0;
}

.card_title span
{
	font-size: 1.1rem;
	font-weight: 400;
}

.card_title a
{
	font-weight: bold;
}

.card_title a:hover
{
	text-decoration: underline;
}

.card_meta
{
	display: flex;
	justify-content: space-between;
	align-items: center;
	font-size: 0.85rem;
	color: var(--gray-text);
}

.card_author
{
	text-overflow: ellipsis;
}

.card_author a:hover
{
	text-decoration: underline;
}

.highlight
{
	color: var(--primary-orange);
	font-weight: 650;
}

.card_diff
{
	display: flex;
	flex-direction: column;
	gap: 5px;
	padding: 5px;
	font-family: 'Fira Code';
	font-size: .9rem;

	border-left: 4px solid var(--primary-orange);
}

.card_stats
{
	display: flex;
	gap: 10px;
}

.manage_actions
{
	display: flex;
	gap: 10px;
}

.action_btn
{
	display: flex;
	align-items: center;
	justify-content: center;
	background: var(--element-bg-primary);
	border: 1px solid #444;
	color: #aaa;
	text-decoration: none;
	cursor: pointer;
	border-radius: 4px;
	transition: all .2s ease;
	box-shadow: var(--secondary-shadow);
	margin: 0;
	padding: 3px;
}

.action_btn:hover
{
	background-color: var(--off-orange);
	border-color: var(--secondary-orange);
}

.action_btn.delete:hover
{
	background-color: #880000;
	border-color: red;
}

.action_btn img
{
	width: 32px;
	height: 32px;
}

.action_btn.view
{
	width: 40px;
	height: 40px;
	font-size: 26px;
	padding: 4px 8px 8px;
	vertical-align: center;
}