/*
Theme Name: Vivement Noël
Description: Un magazine de Noël en français pour les jeunes familles.
Version: 1.1.0
Requires at least: 6.4
Requires PHP: 7.4
Text Domain: vivement-noel
*/

@font-face {
	font-family: Bricolage Grotesque;
	src: url(assets/bricolage.woff2) format("woff2");
	font-weight: 500 800;
	font-display: swap;
}
@font-face {
	font-family: DM Sans;
	src: url(assets/dm-sans.woff2) format("woff2");
	font-weight: 400 700;
	font-display: swap;
}
@font-face {
	font-family: Instrument Serif;
	src: url(assets/instrument-italic.woff2) format("woff2");
	font-style: italic;
	font-display: swap;
}
:root {
	--cream: #f9f5ea;
	--paper: #fffdf6;
	--ink: #182d24;
	--green: #173c2d;
	--red: #bf292b;
	--red-dark: #992125;
	--blush: #f3d0cd;
	--line: #dcd6c6;
	--display: "Bricolage Grotesque", "Arial Black", sans-serif;
	--body: "DM Sans", system-ui, sans-serif;
	--accent: "Instrument Serif", Georgia, serif;
}
*, *::before, *::after { box-sizing: border-box; }
html { scroll-padding-top: 1rem; }
body { margin: 0; background: var(--cream); color: var(--ink); font: 400 16px/1.55 var(--body); }
h1, h2, h3, p, figure { margin: 0; }
h1, h2, h3 { font-family: var(--display); font-weight: 800; }
a { color: inherit; }
img { max-width: 100%; height: auto; display: block; }
button, input { font: inherit; }
button, summary { cursor: pointer; }
:focus-visible { outline: 3px solid var(--red); outline-offset: 4px; }
.wrap { width: min(100% - 88px, 1272px); margin-inline: auto; }
.skip-link { position: absolute; left: 1rem; top: 0; z-index: 9; background: white; padding: .7rem 1rem; transform: translateY(-150%); }
.skip-link:focus { transform: translateY(0); }
.masthead-strip {
	background: var(--red); color: white; min-height: 32px; padding: 7px 12px; text-align: center;
	font-size: .65rem; font-weight: 700; letter-spacing: .16em; line-height: 1.6; text-transform: uppercase;
}
.masthead-strip span { margin-inline: .55em; color: #ffd9b6; }
.site-header { border-bottom: 1px solid var(--line); }
.header-inner { display: flex; min-height: 80px; align-items: center; justify-content: space-between; gap: 1.2rem; }
.wordmark {
	position: relative; flex: none; display: inline-flex; flex-direction: column; width: fit-content;
	color: var(--red-dark); font: 800 clamp(1.35rem, 2.5vw, 1.88rem)/.82 var(--display); letter-spacing: -.08em; text-decoration: none;
}
.wordmark > span { display: flex; align-items: center; gap: .3rem; }
.brand-star { font: 500 1.05rem/1 var(--body); }
.site-nav { display: flex; align-items: center; gap: clamp(.9rem, 2.8vw, 2.7rem); }
.site-nav a, .footer-nav a { font-weight: 700; font-size: .88rem; text-decoration: none; }
.site-nav a:hover, .site-nav a[aria-current] { color: var(--red-dark); text-decoration: underline; text-underline-offset: .3em; }
.search-popover { position: relative; flex: none; }
.search-popover summary, .back-top {
	list-style: none; width: 45px; height: 45px; border: 1px solid currentColor; border-radius: 50%;
	display: grid; place-items: center; text-decoration: none;
}
.search-popover summary::-webkit-details-marker { display: none; }
.search-popover[open] summary, .search-popover summary:hover { background: var(--green); color: white; }
.site-search { display: flex; flex-wrap: wrap; gap: .5rem; }
.search-popover .site-search {
	position: absolute; z-index: 5; right: 0; top: 57px; width: min(23rem, 85vw);
	border: 1px solid var(--line); border-radius: 16px; padding: .8rem; background: var(--paper);
	box-shadow: 0 8px 20px #19271915;
}
.site-search input { flex: 1; min-width: 10ch; width: 10ch; border: 1px solid var(--line); border-radius: 10px; padding: .6rem .7rem; color: var(--ink); background: white; }
.site-search button { border: 0; border-radius: 10px; padding: .6rem .9rem; background: var(--green); color: white; font-weight: 700; }
.hero {
	display: grid; grid-template-columns: minmax(320px, .83fr) minmax(0, 1.17fr); gap: clamp(28px, 4.8vw, 74px);
	padding-block: clamp(32px, 4.4vw, 66px) clamp(38px, 4.8vw, 72px); align-items: center;
}
.hero-copy { padding-block: .5rem; }
.eyebrow { display: flex; align-items: center; gap: .65em; color: var(--red-dark); font-size: .72rem; font-weight: 700; letter-spacing: .14em; text-transform: uppercase; }
.eyebrow span { font-size: 1.05em; }
.hero h1 { font-size: clamp(4.5rem, 8.5vw, 8.6rem); line-height: .81; letter-spacing: -.085em; margin: .19em 0 .21em -.055em; }
h1 em, h2 em { font-family: var(--accent); font-weight: 400; letter-spacing: -.02em; }
.hero h1 em { color: var(--red); display: inline-block; line-height: .67; transform: rotate(-6deg) translateX(.07em); }
.hero-intro { font-size: clamp(1rem, 1.45vw, 1.23rem); max-width: 34ch; margin-block: 1.9rem 1.65rem; }
.vn-button {
	display: inline-flex; gap: 1rem; justify-content: space-between; align-items: center;
	min-height: 48px; max-width: 100%; padding: .65rem 1.18rem; border-radius: 999px;
	background: var(--red); color: white; text-decoration: none; font-weight: 700; font-size: .9rem;
}
.vn-button span { font-size: 1.16em; }
.vn-button:hover { background: var(--red-dark); }
.hero-photo {
	isolation: isolate; position: relative; align-self: stretch; min-height: 448px;
	border-radius: 47% 47% 20px 20px / 31% 31% 20px 20px;
	background: #5b372f; box-shadow: 7px 7px 0 var(--blush);
}
.hero-photo img { position: absolute; width: 100%; height: 100%; object-fit: cover; object-position: 52% 50%; border-radius: inherit; }
.hero-photo figcaption { position: absolute; bottom: 16px; right: 16px; }
.hero-photo figcaption a { display: inline-flex; gap: .9rem; padding: .65rem 1rem; background: var(--paper); border-radius: 999px; text-decoration: none; font-weight: 700; font-size: .8rem; }
.hero-photo figcaption a:hover { background: var(--blush); }
.topics-band { background: var(--green); color: var(--paper); }
.topics-inner { display: grid; grid-template-columns: repeat(6, 1fr); }
.topics-inner a {
	display: flex; justify-content: center; align-items: center; gap: .55rem; min-height: 61px; padding: .35rem;
	font-size: .87rem; font-weight: 700; text-decoration: none; border-inline-end: 1px solid #f9f5ea3d;
}
.topics-inner a:first-child { border-inline-start: 1px solid #f9f5ea3d; }
.topics-inner a span { color: #ffd1b3; font-size: 1.2rem; line-height: 1; }
.topics-inner a:hover { background: #285341; }
.topics-inner a:focus-visible { outline-color: #ffd1b3; outline-offset: -5px; }
.edition { padding-block: clamp(49px, 6vw, 90px); }
.section-heading { margin-bottom: clamp(1.6rem, 3.3vw, 2.8rem); }
.section-heading h1, .section-heading h2, .print-feature h2 {
	font-size: clamp(2.7rem, 6.2vw, 6rem); letter-spacing: -.07em; line-height: .91;
}
.section-heading .eyebrow { margin-bottom: .9rem; }
.section-heading em, .print-feature em { color: var(--red-dark); }
.story-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(15px, 2.1vw, 31px); }
.story-card { background: var(--paper); border: 1px solid var(--line); border-radius: 18px; overflow: clip; }
.story-card:focus-within { outline: 3px solid var(--red-dark); outline-offset: 4px; }
.story-link { display: flex; flex-direction: column; height: 100%; text-decoration: none; }
.story-photo { background: var(--blush); overflow: hidden; aspect-ratio: 16 / 10; }
.story-photo:empty { display: none; }
.story-photo img { width: 100%; height: 100%; object-fit: cover; transition: transform .35s ease; }
.story-link:hover img { transform: scale(1.045); }
.story-body { display: flex; flex: 1; flex-direction: column; padding: clamp(14px, 2vw, 26px); }
.story-topic { color: var(--red-dark); font-size: .68rem; font-weight: 700; text-transform: uppercase; letter-spacing: .13em; margin-bottom: .45rem; }
.story-card :is(h2, h3) { font-size: clamp(1.24rem, 2.25vw, 2.05rem); letter-spacing: -.045em; line-height: 1; }
.story-excerpt { font-size: .9rem; margin-block: .65rem .9rem; }
.story-bottom { display: flex; justify-content: space-between; align-items: center; gap: .55rem; margin-top: auto; font-size: .72rem; font-weight: 700; }
.story-arrow { display: grid; place-items: center; width: 34px; height: 34px; flex: none; border-radius: 50%; border: 1px solid var(--line); font-size: 1rem; }
.story-link:hover .story-arrow { color: white; background: var(--red); border-color: var(--red); }
.print-feature {
	display: grid; grid-template-columns: 1.15fr 1fr; align-items: center;
	margin-bottom: clamp(50px, 7vw, 100px); background: var(--blush); border-radius: 22px; overflow: hidden;
}
.print-feature > div { padding: clamp(22px, 5vw, 70px); }
.print-feature > img { width: 100%; height: 100%; max-height: 480px; object-fit: cover; }
.print-feature h2 { margin-block: .22em .25em; }
.print-feature p:not(.eyebrow) { margin-bottom: 1.4rem; max-width: 36ch; }
.site-footer { background: var(--green); color: var(--paper); padding-block: 2.5rem; }
.footer-inner { display: flex; justify-content: space-between; align-items: flex-start; gap: 1.4rem; }
.site-footer .wordmark { color: var(--blush); }
.site-footer p { margin-top: .8rem; font-size: .84rem; }
.footer-nav { display: flex; flex-wrap: wrap; gap: .55rem 1rem; }
.footer-nav a:hover { text-decoration: underline; }
.back-top { flex: none; }
.back-top:hover { background: var(--paper); color: var(--green); }
.listing { padding-block: clamp(34px, 7vw, 95px); min-height: 57vh; }
.listing-heading { max-width: 48rem; }
.breadcrumb { display: inline-block; font-size: .82rem; font-weight: 700; color: var(--red-dark); margin-bottom: 1.05rem; text-underline-offset: .2em; }
.listing-intro, .listing-heading > p, .listing-heading .site-search, .listing-heading .vn-button { margin-top: 1.2rem; }
.pagination { margin-top: 2rem; }
.pagination .nav-links { display: flex; flex-wrap: wrap; gap: .8rem; }
.article-page { padding-block: clamp(33px, 6vw, 74px); }
.article-heading, .article-content { max-width: 740px; margin-inline: auto; }
.article-heading h1 { font-size: clamp(2.6rem, 7vw, 6.4rem); letter-spacing: -.07em; line-height: .94; overflow-wrap: anywhere; }
.article-intro { font-size: clamp(1.05rem, 2vw, 1.38rem); margin-top: 1.05rem; }
.practical { display: inline-block; background: var(--blush); border-radius: 999px; padding: .35rem .75rem; margin-top: 1rem; font-size: .82rem; font-weight: 700; }
.article-photo { max-width: 960px; margin: 2rem auto; border-radius: 20px; overflow: hidden; }
.article-photo img { width: 100%; max-height: 500px; object-fit: cover; }
.article-content { margin-top: 2rem; }
.article-content h2 { margin-top: 1.2em; font-size: clamp(1.55rem, 3.4vw, 2.7rem); letter-spacing: -.055em; line-height: 1; }
.article-content p, .article-content ul, .article-content ol { margin-top: .85em; }
.article-content li + li { margin-top: .5em; }
.article-content a:not(.vn-button) { color: var(--red-dark); text-underline-offset: .19em; overflow-wrap: anywhere; }
@media (max-width: 880px) {
	.wrap { width: calc(100% - 44px); }
	.hero { grid-template-columns: minmax(242px, .9fr) minmax(0, 1.1fr); gap: 24px; }
	.hero h1 { font-size: clamp(4rem, 10.8vw, 7rem); }
	.hero-photo { min-height: 392px; }
	.site-nav { gap: .95rem; }
}
@media (max-width: 650px) {
	.wrap { width: calc(100% - 32px); }
	.header-inner { display: grid; grid-template-columns: 1fr auto; row-gap: .45rem; padding-block: .85rem .6rem; min-height: auto; }
	.site-nav { grid-column: 1 / -1; grid-row: 2; flex-wrap: wrap; justify-content: space-between; gap: .3rem .55rem; padding: .45rem .2rem; }
	.site-nav a { font-size: .79rem; }
	.search-popover { grid-row: 1; grid-column: 2; }
	.search-popover summary { width: 40px; height: 40px; }
	.hero { grid-template-columns: 1fr; gap: 24px; padding-block: 29px 34px; }
	.hero-copy { padding: 0; }
	.hero h1 { font-size: clamp(4.4rem, 16.4vw, 7.3rem); }
	.hero-intro { margin-block: 1.3rem 1rem; }
	.hero-photo { min-height: auto; aspect-ratio: 1.24; }
	.hero-photo figcaption { bottom: 9px; right: 9px; }
	.hero-photo figcaption a { padding: .48rem .75rem; }
	.topics-inner { grid-template-columns: repeat(3, 1fr); }
	.topics-inner a { min-height: 48px; font-size: .76rem; }
	.topics-inner a:nth-child(4) { border-inline-start: 1px solid #f9f5ea3d; }
	.topics-inner a:nth-child(n+4) { border-top: 1px solid #f9f5ea3d; }
	.story-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
	.story-body { padding: 13px; }
	.story-photo { aspect-ratio: 1.15; }
	.story-arrow { width: 27px; height: 27px; }
	.print-feature { grid-template-columns: 1fr; }
	.print-feature > img { max-height: 265px; }
	.footer-inner { flex-wrap: wrap; }
	.footer-nav { order: 3; width: 100%; }
}
@media (max-width: 374px) {
	.story-grid { grid-template-columns: 1fr; }
}
@media (prefers-reduced-motion: reduce) {
	*, *::before, *::after { transition: none !important; }
}

.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1.15rem; }
.advent-jump {
	display: inline-block; font-size: .86rem; font-weight: 700; color: var(--red-dark);
	text-underline-offset: .22em; text-decoration-thickness: 1px;
}
.advent { padding-block: clamp(45px, 6vw, 82px) 0; scroll-margin-top: 1.25rem; }
.advent-heading { display: flex; gap: 1.5rem 2.5rem; flex-wrap: wrap; justify-content: space-between; align-items: end; }
.advent-heading h2 { font-size: clamp(2.6rem, 5.5vw, 5rem); }
.advent-heading > div:first-child > p { margin-top: .8rem; max-width: 43ch; }
.christmas-countdown {
	min-width: min(100%, 20rem); background: var(--green); color: var(--paper);
	border-radius: 15px; padding: .7rem 1.05rem .85rem;
}
.countdown-title { font-size: .72rem; color: var(--blush); text-transform: uppercase; font-weight: 700; letter-spacing: .13em; }
.countdown-values { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: .6rem; margin-top: .3rem; }
.countdown-values[hidden] { display: none; }
.countdown-values > span { text-align: center; }
.countdown-values strong { display: block; font: 750 1.62rem/1.05 var(--display); font-variant-numeric: tabular-nums; }
.countdown-values small { font-size: .64rem; }
.countdown-message { font: 750 1.7rem/1.1 var(--display); margin-top: .3rem; }
.advent-body { display: grid; grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr); gap: .85rem; }
.advent-grid { display: grid; grid-template-columns: repeat(8, minmax(0, 1fr)); gap: .45rem; }
.advent-door {
	display: grid; place-items: center; min-width: 0; min-height: 43px; aspect-ratio: 1.13;
	border: 1px solid var(--line); border-radius: 10px; background: var(--paper);
	color: var(--green); cursor: pointer; font: 800 clamp(1rem, 2.05vw, 1.68rem)/1 var(--display);
}
.advent-door[data-state="locked"] { background: #eae4d6; color: #5a574d; }
.advent-door[data-state="open"] { color: var(--red-dark); border-color: var(--red-dark); }
.advent-door.is-today, .advent-door[aria-pressed="true"] { background: var(--red-dark); color: var(--paper); border-color: var(--red-dark); }
.advent-door[data-state="locked"][aria-pressed="true"] { background: #eae4d6; color: var(--red-dark); box-shadow: inset 0 0 0 1px var(--red-dark); }
.advent-door:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }
.advent-idea {
	display: flex; flex-direction: column; justify-content: center; align-items: start; gap: .5rem;
	min-height: 136px; padding: clamp(16px, 3vw, 28px);
	border-radius: 15px; background: var(--blush); color: var(--green);
}
.advent-idea h3 { font-size: clamp(1.35rem, 2.8vw, 2.2rem); letter-spacing: -.05em; line-height: 1; }

.family-playlist { margin-bottom: 2.1rem; }
.playlist-screen {
	display: grid; place-items: center; width: 100%; min-height: clamp(200px, 45vw, 380px);
	background: var(--green); border-radius: 18px; overflow: hidden;
}
.playlist-screen iframe { display: block; width: 100%; min-height: 200px; height: auto; aspect-ratio: 16 / 9; border: 0; }
.playlist-start {
	display: inline-flex; gap: .7rem; align-items: center; justify-content: center;
	margin: 1rem; min-height: 48px; padding: .7rem 1.25rem;
	border: 0; border-radius: 100px; background: var(--paper); color: var(--green);
	font: 750 1rem/1.3 var(--body); cursor: pointer;
}
.playlist-start:hover { background: var(--blush); }
.playlist-start:focus-visible { outline: 3px solid var(--paper); outline-offset: 4px; }
.playlist-start > span { color: var(--red-dark); }
.article-content .playlist-note { margin-top: .45rem; font-size: .78rem; }
.article-content .playlist-tracks { list-style: none; padding: 0; }
.playlist-track {
	display: flex; justify-content: space-between; align-items: center; gap: .6rem;
	width: 100%; min-height: 54px; padding: .65rem .85rem; text-align: left;
	border: 1px solid var(--line); border-radius: 10px; background: var(--paper); color: var(--green);
	cursor: pointer; font: 400 1rem/1.3 var(--body);
}
.playlist-track strong, .playlist-track small { display: block; }
.playlist-track > span:last-child { color: var(--red-dark); }
.playlist-track:hover, .playlist-track[aria-current="true"] { background: var(--blush); border-color: var(--red-dark); }
.playlist-track:focus-visible { outline: 2px solid var(--green); outline-offset: 2px; }

@media (max-width: 800px) {
	.advent-body { grid-template-columns: 1fr; }
	.advent-grid { grid-template-columns: repeat(6, minmax(0, 1fr)); }
	.advent-idea { min-height: 6rem; }
}
@media (max-width: 470px) {
	.advent-door { border-radius: 7px; }
	.advent-grid { gap: .32rem; }
}
