/* Dev updates (/devupdates/): the team's logbook for the community.
   Cosy by design: dawn sky from the Aether Ceiling brand (assets/ceiling.css tokens), soft cards, warm touches.
   Linked after site.css and ceiling.css, with a content hash (scripts/build-devupdates.js). */

.du-body {
  --du-ink: var(--ceiling-ink, #0F1E3F);
  --du-ink-soft: var(--ceiling-ink-soft, #34456B);
  --du-card: var(--ceiling-card-bg, #fff);
  --du-line: var(--ceiling-card-border, #DCE6F7);
  --du-wash: var(--ceiling-wash, #F3F8FF);
  --du-sun: var(--ceiling-sun, #F5A04A);
  --du-shadow: 0 18px 40px -26px rgba(15, 30, 63, 0.35);
  /* project colours (background, text) */
  --p-planner-bg: #E3ECFF; --p-planner-fg: #1B46B0;
  --p-aetherfind-bg: #DDF3EC; --p-aetherfind-fg: #0C6650;
  --p-planchette-bg: #EDE6FB; --p-planchette-fg: #5A3FB0;
  --p-ios-bg: #E1F0FB; --p-ios-fg: #14609C;
  --p-vertex-bg: #FDEBD3; --p-vertex-fg: #8F5409;
}
html[data-theme="dark"] .du-body {
  --du-shadow: 0 18px 40px -26px rgba(0, 0, 0, 0.7);
  --p-planner-bg: rgba(110, 150, 255, 0.16); --p-planner-fg: #A9C0FF;
  --p-aetherfind-bg: rgba(92, 201, 138, 0.14); --p-aetherfind-fg: #8FE0B8;
  --p-planchette-bg: rgba(170, 140, 255, 0.16); --p-planchette-fg: #C9B8FF;
  --p-ios-bg: rgba(100, 180, 240, 0.15); --p-ios-fg: #9CD2F7;
  --p-vertex-bg: rgba(245, 160, 74, 0.16); --p-vertex-fg: #FFC98A;
}
@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] .du-body {
    --du-shadow: 0 18px 40px -26px rgba(0, 0, 0, 0.7);
    --p-planner-bg: rgba(110, 150, 255, 0.16); --p-planner-fg: #A9C0FF;
    --p-aetherfind-bg: rgba(92, 201, 138, 0.14); --p-aetherfind-fg: #8FE0B8;
    --p-planchette-bg: rgba(170, 140, 255, 0.16); --p-planchette-fg: #C9B8FF;
    --p-ios-bg: rgba(100, 180, 240, 0.15); --p-ios-fg: #9CD2F7;
    --p-vertex-bg: rgba(245, 160, 74, 0.16); --p-vertex-fg: #FFC98A;
  }
}

/* ---------- hero: a dawn sky, a few clouds ---------- */
.du-hero, .du-post-hero { position: relative; overflow: hidden; isolation: isolate; background: var(--ceiling-grad-sky); color: var(--du-ink); }
.du-hero { padding: clamp(56px, 9vw, 104px) 0 clamp(96px, 12vw, 150px); }
.du-post-hero { padding: clamp(36px, 5vw, 60px) 0 clamp(70px, 9vw, 104px); }
.du-hero-in, .du-post-hero-in { position: relative; z-index: 2; }
.du-hero-in > *, .du-post-hero-in > * { max-width: 780px; }
.du-hero-in > .du-hero-cta { max-width: none; }
.du-hero::before { content: ''; position: absolute; right: 9%; bottom: 22%; width: 120px; height: 120px; border-radius: 50%; z-index: 0; background: radial-gradient(circle, var(--ceiling-sun-glow, #FFC98A) 0%, rgba(255, 201, 138, 0) 70%); opacity: 0.75; }
.du-eyebrow { margin: 0 0 14px; font-family: 'IBM Plex Mono', monospace; font-size: 12px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
.du-hero h1 { margin: 0 0 18px; font-family: 'Sora', sans-serif; font-weight: 700; font-size: clamp(34px, 6vw, 60px); line-height: 1.06; letter-spacing: -0.02em; color: var(--du-ink); text-wrap: balance; }
.du-hand { font-family: 'Caveat', cursive; font-weight: 700; font-size: 1.28em; line-height: 0.8; color: var(--accent); }
.du-lead { margin: 0; max-width: 640px; font-size: clamp(16px, 2vw, 19px); line-height: 1.6; color: var(--du-ink-soft); text-wrap: pretty; }
.du-hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.du-clouds { position: absolute; left: 0; right: 0; bottom: 0; height: 120px; z-index: 1; pointer-events: none; }
.du-clouds i { position: absolute; bottom: -34px; border-radius: 50%; background: var(--ceiling-cloud-front, var(--bg)); }
.du-clouds .c1 { left: -4%; width: 38%; height: 90px; opacity: 0.55; background: var(--ceiling-cloud-mid-c, rgba(255, 255, 255, 0.7)); }
.du-clouds .c2 { left: 26%; width: 52%; height: 110px; bottom: -58px; }
.du-clouds .c3 { right: -6%; width: 44%; height: 96px; bottom: -40px; opacity: 0.8; }
@media (prefers-reduced-motion: no-preference) {
  .du-clouds .c1 { animation: du-drift 38s ease-in-out infinite alternate; }
  .du-clouds .c3 { animation: du-drift 46s ease-in-out infinite alternate-reverse; }
}
@keyframes du-drift { from { transform: translateX(-18px); } to { transform: translateX(26px); } }

/* ---------- buttons ---------- */
.du-btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 22px; border-radius: 100px; font-weight: 600; font-size: 15px; line-height: 1.2; text-decoration: none; border: 1px solid transparent; cursor: pointer; transition: transform 0.2s ease, background 0.2s ease, border-color 0.2s ease; }
.du-btn:hover { transform: translateY(-1px); }
.du-btn svg { width: 14px; height: 14px; }
.du-btn--solid { background: var(--accent); color: #fff; box-shadow: 0 10px 22px -12px rgba(34, 82, 204, 0.7); }
.du-btn--solid:hover { background: var(--accent-dark, #1B46B0); color: #fff; }
.du-btn--glass { background: var(--ceiling-glass-bg, rgba(255, 255, 255, 0.66)); border-color: var(--ceiling-glass-border, rgba(255, 255, 255, 0.8)); color: var(--du-ink); -webkit-backdrop-filter: blur(10px); backdrop-filter: blur(10px); }
.du-btn--line { border-color: var(--du-line); color: var(--du-ink); background: var(--du-card); }
.du-btn--line svg { color: #E8792B; }

.du-wrap { padding-top: 48px; padding-bottom: 110px; }
.du-head { display: flex; align-items: baseline; justify-content: space-between; flex-wrap: wrap; gap: 6px 18px; margin: 0 0 18px; }
.du-head h2 { margin: 0; font-family: 'Sora', sans-serif; font-weight: 700; font-size: clamp(22px, 3vw, 28px); letter-spacing: -0.015em; }
.du-head p, .du-head a { margin: 0; font-size: 14.5px; color: var(--text-muted); }
.du-head a { font-weight: 600; color: var(--accent); }

/* ---------- chips and tags ---------- */
.du-chip, .du-kind, .du-badge { display: inline-flex; align-items: center; padding: 4px 11px; border-radius: 100px; font-family: 'IBM Plex Mono', monospace; font-size: 11px; font-weight: 600; letter-spacing: 0.04em; line-height: 1.3; white-space: nowrap; }
.du-chip { background: var(--p-bg, var(--du-wash)); color: var(--p-fg, var(--accent)); }
.du-chip--planner { --p-bg: var(--p-planner-bg); --p-fg: var(--p-planner-fg); }
.du-chip--aetherfind { --p-bg: var(--p-aetherfind-bg); --p-fg: var(--p-aetherfind-fg); }
.du-chip--planchette { --p-bg: var(--p-planchette-bg); --p-fg: var(--p-planchette-fg); }
.du-chip--ios { --p-bg: var(--p-ios-bg); --p-fg: var(--p-ios-fg); }
.du-chip--vertex { --p-bg: var(--p-vertex-bg); --p-fg: var(--p-vertex-fg); }
.du-chip:hover { filter: brightness(0.96); }
.du-kind { border: 1px solid var(--du-line); color: var(--du-ink-soft); background: transparent; }
.du-kind--fix { border-color: rgba(229, 72, 77, 0.4); color: #C4343A; }
.du-kind--wip { border-color: rgba(245, 160, 74, 0.55); color: #A9620C; }
.du-kind--new { border-color: rgba(34, 82, 204, 0.3); color: var(--accent); }
html[data-theme="dark"] .du-kind--fix { color: #FF9A9E; }
html[data-theme="dark"] .du-kind--wip { color: #FFC98A; }
html[data-theme="dark"] .du-kind--new { color: #A9C0FF; }
@media (prefers-color-scheme: dark) {
  html[data-theme="auto"] .du-kind--fix { color: #FF9A9E; }
  html[data-theme="auto"] .du-kind--wip { color: #FFC98A; }
  html[data-theme="auto"] .du-kind--new { color: #A9C0FF; }
}
.du-badge { background: var(--du-sun); color: #3A2205; }
.du-card-tags { display: flex; flex-wrap: wrap; align-items: center; gap: 6px 8px; }
.du-meta { font-size: 12.5px; color: var(--text-faint, var(--text-muted)); }

/* ---------- "En ce moment" ---------- */
.du-now { margin-bottom: 56px; }
.du-now-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; margin: 0; padding: 0; list-style: none; }
.du-now-card { position: relative; display: flex; flex-direction: column; gap: 8px; height: 100%; padding: 18px 18px 16px; border: 1px solid var(--du-line); border-radius: 20px; background: var(--du-card); color: var(--text); box-shadow: var(--du-shadow); transition: transform 0.2s ease, border-color 0.2s ease; }
.du-now-card::before { content: ''; position: absolute; left: 18px; right: 18px; top: 0; height: 3px; border-radius: 0 0 4px 4px; background: var(--p-fg, var(--accent)); }
.du-now-card--planner { --p-fg: var(--p-planner-fg); }
.du-now-card--aetherfind { --p-fg: var(--p-aetherfind-fg); }
.du-now-card--planchette { --p-fg: var(--p-planchette-fg); }
.du-now-card--ios { --p-fg: var(--p-ios-fg); }
.du-now-card--vertex { --p-fg: var(--p-vertex-fg); }
.du-now-card:hover { transform: translateY(-3px); border-color: var(--p-fg, var(--accent)); color: var(--text); }
.du-now-top { display: flex; flex-direction: column; gap: 6px; }
.du-now-top strong { font-family: 'Sora', sans-serif; font-size: 15.5px; line-height: 1.25; }
.du-status { align-self: flex-start; padding: 2px 9px; border-radius: 100px; background: var(--du-wash); color: var(--du-ink-soft); font-family: 'IBM Plex Mono', monospace; font-size: 10.5px; font-weight: 600; letter-spacing: 0.03em; }
.du-now-blurb { font-size: 13.5px; line-height: 1.5; color: var(--text-muted); }
.du-now-go { margin-top: auto; padding-top: 4px; font-size: 13px; font-weight: 600; color: var(--p-fg, var(--accent)); }

/* ---------- filters ---------- */
.du-filters { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 22px; }
.du-filter { display: inline-flex; align-items: center; gap: 7px; padding: 8px 15px; border: 1px solid var(--du-line); border-radius: 100px; background: var(--du-card); color: var(--text-muted); font: 600 13px 'Work Sans', sans-serif; cursor: pointer; white-space: nowrap; transition: border-color 0.15s ease, color 0.15s ease, background 0.15s ease; }
.du-filter span { font-family: 'IBM Plex Mono', monospace; font-size: 11px; font-weight: 500; opacity: 0.7; }
.du-filter:hover { border-color: var(--accent); color: var(--accent); }
.du-filter[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: #fff; }

/* ---------- lead post and grid ---------- */
.du-lead-post { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 0; border: 1px solid var(--du-line); border-radius: 26px; overflow: hidden; background: var(--du-card); box-shadow: var(--du-shadow); margin-bottom: 26px; }
.du-lead-media { display: block; min-height: 280px; background: var(--du-wash); overflow: hidden; }
.du-lead-media img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: 20% center; transition: transform 0.7s ease; }
.du-lead-post:hover .du-lead-media img { transform: scale(1.03); }
.du-lead-body { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; gap: 14px; padding: clamp(22px, 3.5vw, 40px); }
.du-lead-body h3 { margin: 0; font-family: 'Sora', sans-serif; font-weight: 700; font-size: clamp(22px, 2.8vw, 30px); line-height: 1.15; letter-spacing: -0.015em; }
.du-lead-body h3 a, .du-card h3 a { color: var(--text); }
.du-lead-body h3 a:hover, .du-card h3 a:hover { color: var(--accent); }
.du-lead-body p { margin: 0; font-size: 15.5px; line-height: 1.6; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 4; -webkit-box-orient: vertical; overflow: hidden; }
.du-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px; }
.du-grid--3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.du-card { position: relative; display: flex; flex-direction: column; border: 1px solid var(--du-line); border-radius: 20px; overflow: hidden; background: var(--du-card); box-shadow: var(--du-shadow); transition: transform 0.2s ease, border-color 0.2s ease; }
.du-card:hover { transform: translateY(-3px); border-color: var(--accent); }
.du-card-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; background: var(--du-wash); }
.du-card-media img { display: block; width: 100%; height: 100%; object-fit: cover; transition: transform 0.6s ease; }
.du-card:hover .du-card-media img { transform: scale(1.04); }
.du-card-body { display: flex; flex-direction: column; gap: 10px; padding: 16px 18px 18px; flex: 1; }
.du-card h3 { margin: 0; font-family: 'Sora', sans-serif; font-weight: 600; font-size: 17px; line-height: 1.3; letter-spacing: -0.01em; }
.du-card h3 a::after { content: ''; position: absolute; inset: 0; z-index: 1; }
.du-card-tags a { position: relative; z-index: 2; }
.du-card p { margin: 0; font-size: 14px; line-height: 1.55; color: var(--text-muted); display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.du-card .du-meta { margin-top: auto; }
.du-empty { margin: 24px 0 0; padding: 22px; border: 1px dashed var(--du-line); border-radius: 16px; text-align: center; color: var(--text-muted); }
[data-project][hidden] { display: none !important; }

/* ---------- "à vous la parole" ---------- */
.du-voice { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 20px 32px; margin-top: 64px; padding: clamp(24px, 4vw, 40px); border-radius: 28px; background: var(--ceiling-grad-sky); color: var(--du-ink); position: relative; overflow: hidden; }
.du-voice::after { content: ''; position: absolute; right: -30px; top: -30px; width: 150px; height: 150px; border-radius: 50%; background: radial-gradient(circle, var(--ceiling-sun-glow, #FFC98A) 0%, rgba(255, 201, 138, 0) 70%); opacity: 0.7; pointer-events: none; }
.du-voice-text { position: relative; z-index: 1; max-width: 560px; }
.du-voice-text h2 { margin: 2px 0 8px; font-family: 'Sora', sans-serif; font-weight: 700; font-size: clamp(22px, 3vw, 30px); letter-spacing: -0.015em; color: var(--du-ink); }
.du-voice-text p { margin: 0; font-size: 16px; line-height: 1.6; color: var(--du-ink-soft); }
.du-hand-note { font-family: 'Caveat', cursive; font-weight: 700; font-size: 26px; line-height: 1; color: var(--accent); }
.du-voice-cta { position: relative; z-index: 1; display: flex; flex-wrap: wrap; gap: 10px; }
.du-voice--post { margin-top: 48px; margin-bottom: 8px; }

/* ---------- post page ---------- */
.du-post-hero h1 { margin: 14px 0 14px; font-family: 'Sora', sans-serif; font-weight: 700; font-size: clamp(28px, 4.6vw, 44px); line-height: 1.12; letter-spacing: -0.02em; color: var(--du-ink); text-wrap: balance; }
.du-post-hero .news-crumbs { margin-bottom: 14px; color: var(--du-ink-soft); }
.du-post-hero .news-crumbs a { color: var(--du-ink-soft); }
.du-post-hero .news-byline { margin-top: 22px; border-color: rgba(15, 30, 63, 0.14); }
html[data-theme="dark"] .du-post-hero .news-byline { border-color: rgba(234, 240, 255, 0.18); }
.du-article { padding-bottom: 96px; }
.du-article .news-figure { margin-top: -40px; position: relative; z-index: 3; }
.du-article .news-figure img { box-shadow: var(--du-shadow); border: 1px solid var(--du-line); }
.du-related { padding-top: 48px; }

@media (max-width: 1100px) {
  .du-now-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .du-lead-post { grid-template-columns: minmax(0, 1fr); }
  .du-lead-media { aspect-ratio: 16 / 9; min-height: 0; }
  .du-grid, .du-grid--3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .du-hero::before { right: -20px; bottom: 30%; }
  .du-wrap { padding-top: 32px; }
  /* swipeable rows keep their right margin at the end of the scroll */
  .du-now-grid, .du-filters { display: flex; flex-wrap: nowrap; gap: 12px; margin-left: calc(-1 * var(--gutter)); margin-right: calc(-1 * var(--gutter)); padding: 4px 0 10px var(--gutter); overflow-x: auto; overscroll-behavior-x: contain; scroll-snap-type: x proximity; scroll-padding-inline: var(--gutter); scrollbar-width: none; }
  .du-filters { gap: 8px; margin-bottom: 14px; }
  .du-now-grid::-webkit-scrollbar, .du-filters::-webkit-scrollbar { display: none; }
  .du-now-grid::after { content: ''; flex: 0 0 calc(var(--gutter) - 12px); }
  .du-filters::after { content: ''; flex: 0 0 calc(var(--gutter) - 8px); }
  .du-now-grid > li { flex: 0 0 min(78%, 290px); scroll-snap-align: start; }
  .du-filter { flex: 0 0 auto; scroll-snap-align: start; }
  .du-grid, .du-grid--3 { grid-template-columns: minmax(0, 1fr); gap: 16px; }
  .du-hero-cta .du-btn { flex: 1 1 100%; justify-content: center; }
  .du-article .news-figure { margin-top: -28px; }
  .du-voice-cta .du-btn { flex: 1 1 auto; justify-content: center; }
}
@media (prefers-reduced-motion: reduce) {
  .du-btn, .du-card, .du-now-card, .du-lead-media img, .du-card-media img { transition: none; }
}
