/*
Theme Name: Bien Parti
Author: Bien Parti
Description: Thème éditorial WordPress natif, lumineux et accessible, consacré aux petits progrès du quotidien.
Requires at least: 6.6
Requires PHP: 7.4
Version: 1.1.1
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: bien-parti
Tags: blog, news, block-patterns, block-styles, full-site-editing, accessibility-ready
*/

:root {
  --bp-shadow: 0 12px 34px rgba(36, 51, 43, 0.08);
  --bp-shadow-soft: 0 5px 18px rgba(36, 51, 43, 0.06);
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

a { text-underline-offset: 0.18em; }

:focus-visible {
  outline: 3px solid #f2ce5a;
  outline-offset: 3px;
}

.wp-site-blocks { overflow: hidden; }

.bp-site-header {
  border-bottom: 1px solid rgba(36, 51, 43, 0.10);
  backdrop-filter: blur(12px);
}

.bp-logo a { text-decoration: none; }

.bp-category-nav {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 10px 26px;
}

.bp-category-nav li { margin: 0; }
.bp-category-nav a { color: #24332b; font-size: 0.95rem; font-weight: 600; text-decoration: none; }
.bp-category-nav a:hover { color: #5f8f6a; }

.bp-footer-pages {
  margin: 0;
  padding: 0;
  list-style: none;
}

.bp-footer-pages li { margin-bottom: 0.45rem; }
.bp-footer-pages a { text-decoration: none; }

.bp-hero {
  border-radius: 0 0 28px 28px;
  overflow: hidden;
}

.bp-hero-copy { min-height: 520px; }

.bp-hero-visual {
  min-height: 520px;
  background: #f3eadb;
}

.bp-hero-visual .wp-block-image { height: 100%; margin: 0; }
.bp-hero-visual .wp-block-image img { width: 100%; height: 100%; min-height: 520px; object-fit: cover; }

.bp-card,
.bp-step,
.bp-newsletter,
.bp-toc {
  border: 1px solid rgba(36, 51, 43, 0.10);
  box-shadow: var(--bp-shadow-soft);
}

.bp-card {
  height: 100%;
  transition: transform .2s ease, box-shadow .2s ease;
  overflow: hidden;
}

.bp-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--bp-shadow);
}

.bp-card a { text-decoration: none; }

.bp-icon,
p.bp-icon,
.wp-block-paragraph.bp-icon {
  width: 64px;
  height: 64px;
  min-width: 64px;
  max-width: 64px;
  min-height: 64px;
  max-height: 64px;
  flex: 0 0 64px;
  aspect-ratio: 1 / 1;
  display: flex !important;
  align-items: center;
  justify-content: center;
  padding: 0 !important;
  margin: 0 !important;
  border-radius: 999px !important;
  font-size: 1.7rem;
  line-height: 1;
  text-align: center;
  overflow: hidden;
}

.bp-post-grid .wp-block-post {
  display: flex;
  flex-direction: column;
  background: #fff;
  border: 1px solid rgba(36, 51, 43, 0.10);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--bp-shadow-soft);
}

.bp-post-grid .wp-block-post-featured-image { margin: 0; }
.bp-post-grid .wp-block-post-featured-image img { aspect-ratio: 16 / 10; object-fit: cover; }
.bp-post-grid .wp-block-post-title,
.bp-post-grid .wp-block-post-excerpt,
.bp-post-grid .wp-block-post-date,
.bp-post-grid .wp-block-post-terms { padding-inline: 20px; }
.bp-post-grid .wp-block-post-title { margin-top: 12px; }
.bp-post-grid .wp-block-post-excerpt { margin-bottom: 20px; }

.bp-article-hero .wp-block-post-featured-image img {
  max-height: 620px;
  object-fit: cover;
  border-radius: 22px;
}

.bp-article-body { line-height: 1.78; }
.bp-article-body > * + * { margin-block-start: 1.35em; }
.bp-article-body h2 { margin-block-start: 2.15em; }

.bp-note {
  border-left: 4px solid #f6a66a;
  box-shadow: var(--bp-shadow-soft);
}

.bp-footer { border-top: 1px solid rgba(36, 51, 43, 0.10); }

.wp-block-button.is-style-outline > .wp-block-button__link {
  border-width: 1px;
}

@media (max-width: 781px) {
  .bp-site-header .wp-block-group.alignwide { align-items: flex-start; flex-direction: column; }
  .bp-category-nav { justify-content: flex-start; gap: 8px 18px; }
  .bp-hero-copy,
  .bp-hero-visual { min-height: auto; }
  .bp-hero-visual { min-height: 260px; }
  .bp-hero-visual .wp-block-image img { min-height: 260px; }
  .bp-step .wp-block-buttons { justify-content: flex-start; }
  .bp-article-layout { display: block !important; }
  .bp-toc { margin-bottom: 32px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
