/* L'annonce : une carte postale posée en bas de l'écran */
.annonce { position: fixed; left: 24px; bottom: 24px; z-index: 9990; width: min(380px, calc(100vw - 32px)); color: #1e2a25; }
.annonce[hidden] { display: none; }
.annonce.annonce-avec-photo { width: min(620px, calc(100vw - 32px)); }
.annonce-carte {
	position: relative; display: grid; grid-template-columns: 1fr; overflow: hidden;
	background: #fbfaf5; border-radius: 6px; border: 1px solid #e4e0d3;
	box-shadow: 0 2px 4px rgba(30, 42, 37, .08), 0 18px 40px rgba(30, 42, 37, .22);
	transform: rotate(-1.2deg); transform-origin: 0 100%;
	animation: annonce-arrive .7s cubic-bezier(.2, .9, .3, 1.15) both;
}
.annonce.annonce-part .annonce-carte { animation: annonce-part .35s ease-in both; }
@keyframes annonce-arrive { from { opacity: 0; transform: translateY(70px) rotate(-6deg); } to { opacity: 1; transform: rotate(-1.2deg); } }
@keyframes annonce-part { to { opacity: 0; transform: translateY(50px) rotate(-4deg); } }
.annonce-avec-photo .annonce-carte { grid-template-columns: 44% 1fr; }
.annonce-photo { position: relative; min-height: 100%; background: #e4e0d3; }
.annonce-photo img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; }
/* Au dos d'une carte postale : un trait sépare la photo du texte */
.annonce-corps { position: relative; padding: 26px 26px 22px; min-width: 0;
	background-image: repeating-linear-gradient(transparent 0 31px, rgba(31, 68, 55, .07) 31px 32px); background-position: 0 14px; }
.annonce-avec-photo .annonce-corps { border-left: 1px dashed #cfc8b4; }
.annonce-titre { font-family: var(--wp--preset--font-family--titre, Georgia, serif); font-size: 1.45rem; line-height: 1.2; color: #1f4437; margin: 0 70px 10px 0; font-weight: 400; }
.annonce-texte { font-size: .98rem; line-height: 1.55; }
.annonce-texte p { margin: 0 0 .6em; }
.annonce-texte a { color: #1f4437; }
.annonce-signature { font-family: "Caveat", "Segoe Script", cursive; font-size: 1.75rem; line-height: 1; color: #a5432a; margin: 6px 0 4px; transform: rotate(-3deg); transform-origin: left; }
.annonce-action { margin: 14px 0 0; }
.annonce-bouton { display: inline-block; background: #1f4437; color: #fff !important; text-decoration: none; padding: 10px 18px; border-radius: 999px; font-weight: 600; font-size: .95rem; transition: background .2s, transform .2s; }
.annonce-bouton:hover, .annonce-bouton:focus-visible { background: #a5432a; transform: translateY(-1px); }
/* Le timbre dentelé et le cachet de la poste */
.annonce-timbre { position: absolute; top: 14px; right: 16px; padding: 4px; background: #fff; line-height: 0; transform: rotate(4deg);
	-webkit-mask: radial-gradient(circle at 3px 3px, transparent 2.2px, #000 2.6px) -3px -3px / 7px 7px; mask: radial-gradient(circle at 3px 3px, transparent 2.2px, #000 2.6px) -3px -3px / 7px 7px;
	filter: drop-shadow(0 1px 1px rgba(0, 0, 0, .15)); }
.annonce-cachet { position: absolute; top: 6px; right: 46px; color: rgba(165, 67, 42, .42); transform: rotate(-14deg); pointer-events: none; font-family: var(--wp--preset--font-family--texte, sans-serif); font-weight: 700; }
.annonce-fermer { position: absolute; top: 8px; left: 8px; z-index: 2; width: 34px; height: 34px; border-radius: 50%; border: 0; cursor: pointer;
	background: rgba(255, 255, 255, .92); color: #1e2a25; font-size: 22px; line-height: 1; box-shadow: 0 1px 4px rgba(0, 0, 0, .2); display: flex; align-items: center; justify-content: center; }
.annonce:not(.annonce-avec-photo) .annonce-fermer { left: auto; right: 8px; top: auto; bottom: 8px; background: transparent; box-shadow: none; color: #5a655f; }
.annonce-fermer:hover { background: #fff; color: #a5432a; }
.annonce-fermer:focus-visible, .annonce-bouton:focus-visible { outline: 3px solid #e9b97f; outline-offset: 2px; }

/* Téléphone : la carte devient un volet en bas de l'écran */
@media (max-width: 640px) {
	.annonce, .annonce.annonce-avec-photo { left: 8px; right: 8px; bottom: 8px; width: auto; }
	.annonce-carte { transform: none; animation-name: annonce-monte; max-height: calc(100vh - 80px); overflow-y: auto; }
	@keyframes annonce-monte { from { opacity: 0; transform: translateY(100%); } to { opacity: 1; transform: none; } }
	.annonce-avec-photo .annonce-carte { grid-template-columns: 1fr; }
	.annonce-photo { height: 110px; min-height: 0; }
	.annonce-avec-photo .annonce-corps { border-left: 0; border-top: 1px dashed #cfc8b4; }
	.annonce-corps { padding: 20px 18px 18px; }
	.annonce-titre { font-size: 1.25rem; margin-right: 64px; }
	.annonce-cachet { display: none; }
	.annonce-timbre svg { width: 42px; height: 50px; }
}
@media (prefers-reduced-motion: reduce) { .annonce-carte, .annonce.annonce-part .annonce-carte { animation: none; } }
@media print { .annonce { display: none !important; } }
