/*
 * Shared header: the logo, the page title and the "More from Breezy" card.
 * Loaded on the Breezy dashboard and all six tool pages (see Breezy::HEADER_HOOKS in breezy.php).
 * Replaces the copies of these rules that each page's own stylesheet used to hold.
 * Values follow specs/20261011-171327-nicholas.claude.code-header-promo-card.md (prototype v1-4).
 */

.banner-wrapper {
	padding-top: 16px;
}

.banner-wrapper .flex-wrapper {
	display: flex;
	flex-direction: row;
	flex-wrap: nowrap;
	align-items: center;
	gap: 12px;
	box-sizing: border-box;
}

.banner-wrapper .flex-wrapper .left-wrapper {
	flex: 0 0 auto;
}

/* The logo links to the Breezy dashboard; the rounded corners keep the focus ring close to the logo */
.banner-wrapper .flex-wrapper .left-wrapper a {
	display: block;
	border-radius: 14px;
}

.banner-wrapper .flex-wrapper .left-wrapper img {
	display: block;
	max-width: 59px;
	width: 100%;
}

/* 12px gap + 24px margin = at least 36px between the title and the card */
.banner-wrapper .flex-wrapper .right-wrapper {
	display: flex;
	flex-direction: row;
	align-items: center;
	flex: 0 0 auto;
	margin-right: 24px;
}

.banner-wrapper .flex-wrapper .right-wrapper h1 {
	font-weight: 400;
	font-size: 24px;
	line-height: 1.3;
	margin: 0;
	padding: 0;
	white-space: nowrap;
}

/* The card: one link, light green with a thin edge; on hover it lightens and the edge glows */
.breezy-header-card {
	--breezy-card-bg: #F2FAF2;
	--breezy-card-bg-hover: #ffffff;
	--breezy-card-fg: #000000;
	--breezy-card-ring: 0 0 0 1px #CAEACB;
	--breezy-card-ring-hover: 0 0 0 1px #3EB049, 0 0 8px 2px rgba(62, 176, 73, 0.45);
	display: flex;
	flex-direction: column;
	justify-content: center;
	flex: 0 1 auto;
	min-width: 0;
	max-width: 700px;
	margin-left: auto;
	min-height: 59px;
	box-sizing: border-box;
	padding: 5px 14px;
	border-radius: 10px;
	background: var(--breezy-card-bg);
	color: var(--breezy-card-fg);
	box-shadow: var(--breezy-card-ring);
	text-decoration: none;
	cursor: pointer;
	transition: background 0.3s, box-shadow 0.3s;
}

.breezy-header-card.is-fallback {
	flex: 0 0 auto;
	max-width: none;
}

.breezy-header-card > span {
	display: block;
}

.breezy-header-card .card-title {
	font-size: 14px;
	font-weight: 700;
	line-height: 17px;
}

.breezy-header-card .card-blurb,
.breezy-header-card .card-action {
	font-size: 12px;
	line-height: 16px;
}

.breezy-header-card .card-action-text {
	display: inline;
	text-decoration: underline;
}

.breezy-header-card .dashicons {
	width: 14px;
	height: 14px;
	font-size: 14px;
	margin-left: 3px;
	vertical-align: -2px;
}

/* Keyboard focus: a clear outline (WordPress's own link focus ring is replaced) */
.breezy-header-card:focus {
	color: var(--breezy-card-fg);
	outline: 2px solid #135e96;
	outline-offset: 2px;
	box-shadow: var(--breezy-card-ring);
}

.breezy-header-card:hover,
.breezy-header-card:focus:hover,
.breezy-header-card:active {
	background: var(--breezy-card-bg-hover);
	color: var(--breezy-card-fg);
	box-shadow: var(--breezy-card-ring-hover);
	text-decoration: none;
}

/* Phone: 600px is WordPress's own small-screen point. The card drops below the logo and title. */
@media (max-width: 600px) {
	.banner-wrapper .flex-wrapper {
		flex-wrap: wrap;
	}

	.banner-wrapper .flex-wrapper .right-wrapper {
		margin-right: 0;
	}

	.breezy-header-card,
	.breezy-header-card.is-fallback {
		flex: 1 0 100%;
		max-width: none;
		margin-left: 0;
	}
}
