/* SpendeDirekt www pages (partner detail, news detail, donor portal).
   Site chrome (sd-*) comes from the Builder stylesheet linked via
   `sd_styles_url`; this file owns the www page (sdw-*) styles. */
:root { color-scheme: light; } /* no dark theme: keep native controls light */
.sdw-page {
	font-family: 'Open Sans', 'Space Grotesk', Arial, sans-serif;
	color: #000F33; background: #fcfcfc; min-height: 100vh; line-height: 1.6;
}
.sdw-btn {
	display: inline-flex; align-items: center; justify-content: center;
	min-height: 44px; padding: 9px 22px; border-radius: 3px; border: 2px solid transparent;
	font-weight: 700; text-decoration: none; font-size: 15px; cursor: pointer;
}
.sdw-btn-donate { background: #4c7a2c; color: #fff; }
.sdw-btn-donate:hover { background: #3d6123; }
.sdw-btn-ghost { background: transparent; color: #000F33; border-color: #c9cdd8; }
.sdw-btn-small { min-height: 34px; padding: 5px 14px; font-size: 13px; background: #fff; border-color: #c9cdd8; color: #000F33; }
.sdw-btn-block { display: block; width: 100%; margin-top: 14px; text-align: center; box-sizing: border-box; }
.sdw-main { max-width: 1100px; margin: 0 auto; padding: 0 32px; }
.sdw-section { padding: 46px 0; }
.sdw-section-alt { background: #f3f6f2; margin: 0 -32px; padding: 46px 32px; }
.sdw-kicker { text-transform: uppercase; letter-spacing: .16em; font-size: 12px; font-weight: 700; color: #4c7a2c; margin: 0 0 6px; }
.sdw-page h1 { font-family: 'Space Grotesk', sans-serif; font-size: 34px; margin: 0 0 14px; }
.sdw-page h2 { font-family: 'Space Grotesk', sans-serif; font-size: 26px; margin: 0 0 18px; }
.sdw-page h3 { font-size: 20px; margin: 0 0 8px; }
/* Long German compounds and partner names overflowed narrow cards. */
.sdw-page :is(h1, h2, h3, h4) { overflow-wrap: anywhere; hyphens: auto; }

/* partner hero banner (legacy orgaHeader: 40vh, bottom-aligned title where the
   organisation name is the only bold part; the navy ground is ours — legacy
   left it transparent, which loses the white title when an org has no image) */
.sdw-hero {
	background: #000F33; color: #fff; min-height: 40vh;
	display: flex; align-items: flex-end; position: relative; overflow: hidden;
}
/* An <img> rather than a CSS background: srcset picks a size for the screen
   and the browser can prioritise it as the page's largest paint. */
.sdw-hero-img, .sdw-video-poster, .sdw-project-img {
	position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block;
}
.sdw-hero-photo::after {
	content: ""; position: absolute; inset: 0;
	background: linear-gradient(to bottom, rgba(255,255,255,.2), rgba(0,15,51,.05), rgba(0,15,51,.7));
}
.sdw-hero-inner { max-width: 1100px; margin: 0 auto; padding: 90px 32px 26px; width: 100%; position: relative; z-index: 1; }
.sdw-hero h1 {
	color: #fff; margin: 0; font-size: 28px; font-weight: 400;
	text-shadow: 1px 2px 5px rgba(0,0,0,.51);
}
.sdw-hero h1 strong { font-weight: 700; }

/* second navbar (legacy secondNavbar) */
.sdw-secondbar {
	background: #000F33; display: flex; justify-content: center; gap: 6px;
}
.sdw-secondbar a {
	color: #fff; text-decoration: none; font-size: 15px; padding: 10px 18px;
}
.sdw-secondbar a:hover { color: #9ED680; }

/* partner layout: sticky overview card + content */
.sdw-layout { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 2fr); gap: 36px; padding: 40px 0 20px; }
.sdw-aside { min-width: 0; }
.sdw-overview { position: sticky; top: 76px; }
.sdw-card { background: #fff; border: 1px solid #e7e7ea; border-radius: 8px; padding: 22px 24px; }
.sdw-overview-head { display: flex; gap: 18px; align-items: center; }
.sdw-overview-logo { width: 72px; height: 72px; object-fit: contain; flex: 0 0 auto; }
.sdw-overview-tagline { font-weight: 700; font-size: 17px; margin: 0; }
.sdw-socials { display: flex; gap: 22px; justify-content: center; margin: 18px 0 6px; }
.sdw-socials a { color: #000F33; }
.sdw-socials a:hover { color: #4c7a2c; }
.sdw-socials svg { width: 18px; height: 18px; }
.sdw-overview-counts { display: grid; margin-top: 12px; }
.sdw-count-row {
	display: flex; justify-content: space-between; align-items: center; gap: 10px;
	padding: 11px 2px; border-top: 1px solid #efeff2; font-size: 14px;
	color: #000F33; text-decoration: none;
}
.sdw-count-row:hover { color: #4c7a2c; }
.sd-badge {
	display: inline-block; min-width: 26px; padding: 3px 9px; border-radius: 999px;
	color: #fff; font-size: 12px; font-weight: 700; text-align: center;
}
.sd-badge-info { background: #117a8b; }
.sd-badge-secondary { background: #6c757d; }
.sd-badge-success { background: #4c7a2c; }
.sdw-content { display: grid; gap: 24px; align-content: start; min-width: 0; }
.sdw-section-card h2 { margin-top: 0; }

.sdw-partner-logo { max-height: 110px; object-fit: contain; margin-bottom: 16px; }
.sdw-owner-img { width: 100%; max-width: 320px; height: auto; border-radius: 8px; margin-bottom: 14px; }
.sdw-links { display: flex; flex-wrap: wrap; gap: 14px; margin: 14px 0; }
.sdw-links a { color: #4c7a2c; font-weight: 700; text-decoration: none; }
.sdw-video { position: relative; padding-top: 56.25%; }
.sdw-video iframe { position: absolute; top: 0; left: 0; width: 100%; height: 100%; border-radius: 8px; }
.sdw-video-consent {
	background-color: #000F33; overflow: hidden;
	border-radius: 8px; padding-top: 0; min-height: 260px;
	display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px;
}
.sdw-video-consent::before {
	content: ""; position: absolute; inset: 0; z-index: 1;
	background: linear-gradient(to bottom, rgba(0,15,51,.25), rgba(0,15,51,.55));
}
.sdw-video-consent > :not(picture) { position: relative; z-index: 2; }
.sdw-video-play {
	display: inline-flex; align-items: center; gap: 10px; cursor: pointer;
	border: 0; border-radius: 6px; padding: 12px 22px;
	background: #4c7a2c; color: #fff; font: inherit; font-weight: 700; font-size: 15px;
	transition: background .15s;
}
.sdw-video-play:hover { background: #3d6123; }
.sdw-video-play svg { flex: 0 0 auto; }
.sdw-video-note { color: rgba(255,255,255,.85); font-size: 13px; margin: 0; }

/* project cards (legacy projekte grid) */
.sdw-projects-section { padding: 20px 0 56px; }
.sdw-project-group { margin-bottom: 28px; }
.sdw-project-group > summary {
	cursor: pointer; list-style-position: inside; padding: 8px 0; margin-bottom: 14px;
	border-bottom: 1px solid #e7e7ea;
}
.sdw-project-group-title { display: inline; font-size: 20px; margin: 0; }
.sdw-project-group-count { color: #535C7E; font-weight: 400; }
.sdw-projects { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 26px; }
.sdw-project {
	background: #fff; border: 1px solid #e7e7ea; border-radius: 8px; overflow: hidden;
	display: flex; flex-direction: column;
}
.sdw-project-media { aspect-ratio: 4 / 3; position: relative; background: #e7e7ea; }
.sdw-project-body { padding: 18px 20px 22px; display: flex; flex-direction: column; gap: 10px; flex: 1; }
.sdw-project-title { font-family: 'Space Grotesk', sans-serif; font-size: 22px; line-height: 1.2; margin: 0; }
.sdw-project-body p { margin: 0; }
.sdw-project-body .sd-btn { margin-top: auto; align-self: flex-start; }
.sdw-pill {
	display: inline-block; border-radius: 999px; padding: 4px 14px; font-size: 13px;
	font-weight: 700; background: #e7e7ea; color: #535C7E; align-self: flex-start;
}
.sdw-pill-running { background: #e5f3cf; color: #3d6123; }
.sdw-pill-finished { background: #4c7a2c; color: #fff; }
.sdw-pill-planned { background: #dfe3f0; color: #000F33; }
.sdw-progress { height: 8px; border-radius: 4px; background: #e7e7ea; overflow: hidden; }
.sdw-progress > span { display: block; height: 100%; background: #4c7a2c; }
.sdw-project-meta { color: #535C7E; font-size: 14px; }

/* feed */
.sdw-feed { display: grid; }
.sdw-feed-item {
	display: flex; gap: 14px; align-items: center; padding: 13px 0;
	border-top: 1px solid #efeff2; text-decoration: none; color: inherit;
}
.sdw-feed-item:first-child { border-top: 0; }
.sdw-feed-item:hover .sdw-feed-title { color: #4c7a2c; }
.sdw-feed-logo { width: 32px; height: 32px; border-radius: 4px; object-fit: cover; flex: 0 0 auto; }
.sdw-feed-text { flex: 1; min-width: 0; }
.sdw-feed-title { display: block; margin: 1px 0 3px; color: #000F33; font-size: 15px; }
.sdw-feed-date { font-size: 12px; color: #535C7E; display: block; }
.sdw-feed-body { font-size: 14px; color: #333a56; }
.sdw-feed-chevron { color: #535C7E; display: flex; align-items: center; flex: 0 0 auto; }

.sdw-article { max-width: 760px; }
.sdw-article-image { width: 100%; border-radius: 8px; margin: 14px 0; }
.sdw-table { width: 100%; border-collapse: collapse; background: #fff; border: 1px solid #e7e7ea; border-radius: 6px; overflow: hidden; }
.sdw-table th, .sdw-table td { text-align: left; padding: 11px 14px; border-bottom: 1px solid #efeff2; font-size: 14px; }
.sdw-table th { background: #000F33; color: #fff; font-weight: 600; }
.sdw-table td.sd-num, .sdw-table th.sd-num { text-align: right; font-variant-numeric: tabular-nums; }
.sdw-note { font-size: 12px; color: #535C7E; margin-top: 6px; max-width: 340px; }
/* A link inside running text needs more than colour to stand out (axe
   link-in-text-block: "Hier anmelden" was 2.73:1 against the note text). */
.sdw-note a, .sdw-rich a { color: #4c7a2c; text-decoration: underline; }
.sdw-msg { margin-top: 12px; font-weight: 600; color: #4c7a2c; }
.sdw-form { display: grid; gap: 10px; max-width: 460px; margin-top: 18px; }
.sdw-form label { font-weight: 700; font-size: 14px; }
.sdw-form input { border: 1px solid #c9cdd8; border-radius: 4px; padding: 11px 12px; font: inherit; }
.sdw-form input:focus { outline: 2px solid #4c7a2c; border-color: #4c7a2c; }
.sdw-logout { margin: 6px 0 0; }

/* 404 / error pages */
.sdw-error { max-width: 760px; min-height: 50vh; }
.sdw-error-links { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.sdw-error-trace { margin-top: 24px; max-height: 360px; overflow: auto; font-size: 12px; background: #f5f7fa; padding: 12px; border-radius: 6px; }

/* frappe's /login on a SpendeDirekt site: its grey labels and the
   "forgot password" link sit at 4.17:1 on white; the muted navy passes AA. */
.for-login .form-login label, .for-login a[href="#forgot"] { color: #535C7E; }

/* visible keyboard focus (AA): dark green on light grounds, light green on navy */
.sdw-page :is(a, button, summary, select, input, textarea):focus-visible,
.sd-site-header :is(a, summary):focus-visible {
	outline: 2px solid #4c7a2c; outline-offset: 2px; border-radius: 2px;
}
.sd-site-footer a:focus-visible,
.sdw-secondbar a:focus-visible {
	outline: 2px solid #9ED680; outline-offset: 2px; border-radius: 2px;
}

@media (max-width: 900px) {
	.sdw-layout, .sdw-projects { grid-template-columns: minmax(0, 1fr); }
	.sdw-overview { position: static; }
	.sdw-section-alt { margin: 0 -16px; padding: 36px 16px; }
	.sdw-main { padding: 0 16px; }
	.sdw-hero { min-height: 34vh; }
	.sdw-hero-inner { padding: 60px 16px 20px; }
	.sdw-hero h1 { font-size: 24px; }
	}
