/* «Вести добра»: фирменный стиль по брендбуку (Literata + Golos Text, тёплая палитра).
   Цвета только через переменные. Тема: по умолчанию как в системе, переключатель «солнце / лампа» (html[data-theme]). */
:root {
  --bg:#FFF8EE; --surface:#FFFDF8; --text:#3A2A1F; --text2:#6B5444; --accent:#F2A05C; --on-accent:#3A2A1F;
  --accent-text:#B4532A; --badge:#FFD36E; --peach:#FFE6D2; --sage:#3F6B45; --mint:#E4F0DD; --link:#B4532A;
  --sky-a:#FFF1DC; --sky-b:#FFF8EE; --sun:#F2A05C; --sun-glow:none; --sun-blend:multiply;
  --mark-sun:#F2A05C; --mark-body:#3A2A1F; --footer:#33251C; --shadow:0 6px 24px rgba(120,70,30,.08);
  --window-glow:0 6px 24px rgba(120,70,30,.10); --window-bg:#FFF1DC;
  --serif:Literata,Georgia,serif; --sans:"Golos Text",system-ui,sans-serif;
  --maxw:1240px; --pad:32px;
}
html[data-sky="day"]{--sky-a:#FFF8EE;--sky-b:#FFFDF8}
html[data-sky="evening"]{--sky-a:#FFE6D2;--sky-b:#FCE0C8}
@media (prefers-color-scheme:dark){
  html:not([data-theme="light"]){--bg:#241A14;--surface:#33251C;--text:#F7EBDD;--text2:#D3BFAA;--accent:#FFB27A;--on-accent:#241A14;
    --accent-text:#FFB27A;--peach:#3D2A20;--sage:#9CCB9A;--mint:#2E3A2C;--link:#F5A47E;--sky-a:#241A14;--sky-b:#2E2119;
    --sun:#FFB27A;--sun-glow:0 0 120px rgba(255,178,122,.45);--sun-blend:normal;--mark-sun:#FFB27A;--mark-body:#F7EBDD;
    --footer:#1B1410;--shadow:0 0 0 1px rgba(247,235,221,.10);--window-glow:0 0 0 10px rgba(255,178,122,.10),0 0 80px rgba(255,178,122,.30)}
}
html[data-theme="dark"]{--bg:#241A14;--surface:#33251C;--text:#F7EBDD;--text2:#D3BFAA;--accent:#FFB27A;--on-accent:#241A14;
  --accent-text:#FFB27A;--peach:#3D2A20;--sage:#9CCB9A;--mint:#2E3A2C;--link:#F5A47E;--sky-a:#241A14;--sky-b:#2E2119;
  --sun:#FFB27A;--sun-glow:0 0 120px rgba(255,178,122,.45);--sun-blend:normal;--mark-sun:#FFB27A;--mark-body:#F7EBDD;
  --footer:#1B1410;--shadow:0 0 0 1px rgba(247,235,221,.10);--window-glow:0 0 0 10px rgba(255,178,122,.10),0 0 80px rgba(255,178,122,.30)}

*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--bg);color:var(--text);font:400 18px/1.65 var(--sans);transition:background-color .4s ease,color .4s ease}
a{color:var(--link)}
img,svg{max-width:100%}
.wrap{max-width:var(--maxw);margin:0 auto;padding:0 var(--pad)}
:focus-visible{outline:3px solid var(--accent-text);outline-offset:3px;border-radius:6px}
.skip{position:absolute;left:-999px;top:8px;background:var(--text);color:var(--bg);padding:10px 16px;border-radius:999px;z-index:10}
.skip:focus{left:8px}
h1,h2,h3{font-family:var(--serif);font-weight:700;letter-spacing:-.02em;margin:0}
em,.it{font-style:italic;font-weight:600}

/* шапка и небо */
.sky{position:relative;overflow:hidden;background:linear-gradient(180deg,var(--sky-a),var(--sky-b))}
.sun{position:absolute;right:-160px;top:-260px;width:620px;height:620px;border-radius:50%;background:var(--sun);
  box-shadow:var(--sun-glow);mix-blend-mode:var(--sun-blend);pointer-events:none}
.mast{position:relative;display:flex;align-items:center;justify-content:space-between;gap:16px;padding-top:22px;padding-bottom:22px}
.logo{display:flex;align-items:center;gap:10px;color:var(--text);text-decoration:none}
.logo span{font:700 22px/1 var(--serif);letter-spacing:-.02em;white-space:nowrap}
.logo em{font-style:italic;font-weight:600}
.nav{display:flex;gap:32px;font-size:17px;font-weight:500}
.nav a{color:var(--text);text-decoration:none;min-height:48px;display:flex;align-items:center}
.nav a[aria-current="page"]{color:var(--link);font-weight:600}
.mast-end{display:flex;gap:10px;align-items:center}
.icon-btn{width:48px;height:48px;border-radius:50%;border:2px solid var(--text);background:var(--surface);color:var(--text);display:flex;align-items:center;justify-content:center;cursor:pointer;padding:0}
.icon-btn .ic-sun{display:none}
html[data-theme="dark"] .icon-btn .ic-sun{display:block}
html[data-theme="dark"] .icon-btn .ic-lamp{display:none}
.btn,.btn-fill{height:52px;padding:0 28px;border-radius:999px;background:var(--accent);color:var(--on-accent);display:inline-flex;align-items:center;justify-content:center;font:600 17px/1 var(--sans);text-decoration:none;border:0;cursor:pointer;transition:transform .22s ease,box-shadow .22s ease}
.btn:hover{transform:translateY(-2px);box-shadow:0 8px 20px rgba(120,70,30,.18)}
.btn:active{transform:translateY(0)}
.btn-tg{height:48px;padding:0 22px;border-radius:999px;background:var(--text);color:var(--bg);display:flex;align-items:center;font:600 16px/1 var(--sans);text-decoration:none}
.menu-btn{display:none;height:48px;padding:0 18px;border-radius:999px;border:2px solid var(--text);background:transparent;color:var(--text);font:600 16px/1 var(--sans);cursor:pointer}

/* первый экран */
.hero{position:relative;display:flex;flex-direction:row-reverse;flex-wrap:wrap;justify-content:flex-end;align-items:center;gap:56px;padding-top:48px;padding-bottom:88px}
.window{flex:1 1 300px;max-width:360px;height:420px;border-radius:180px 180px 28px 28px;overflow:hidden;background:var(--window-bg);box-shadow:var(--window-glow)}
.window svg{width:100%;height:100%;display:block}
.hero-text{flex:999 1 520px;min-width:0;display:flex;flex-direction:column;gap:20px}
.date{font-size:15px;font-weight:500;color:var(--text2)}
.greet{font-size:19px;font-weight:500;line-height:1.45;margin-top:4px}
.badge{align-self:flex-start;background:var(--badge);color:#3A2A1F;border-radius:999px;padding:7px 14px;font-size:14px;font-weight:600;letter-spacing:.02em}
.h-display{font-size:60px;line-height:1.04;letter-spacing:-.03em;text-wrap:balance}
.h-display .it{color:var(--accent-text)}
.lead{font-size:21px;font-weight:500;line-height:1.55;max-width:620px;margin:0}
.hero-text .draft,.article>.draft{align-self:flex-start}
.draft{display:inline-block;width:fit-content;background:var(--text);color:var(--bg);border-radius:999px;padding:3px 10px;font:600 13px/1.4 var(--sans)}

/* счётчик честности */
.strip{background:var(--mint)}
.strip .wrap{display:flex;flex-wrap:wrap;align-items:center;gap:48px;padding-top:28px;padding-bottom:28px}
.counter{display:flex;align-items:center;gap:16px}
.counter .n{font:700 48px/1 var(--serif);letter-spacing:-.03em}
.counter .n.k{font-style:italic;color:var(--sage)}
.counter .l{font-size:15px;margin-top:8px}
.strip-text{flex:1 1 280px;display:flex;flex-direction:column;gap:4px;font-size:18px}
.strip-text a{font-weight:600;font-size:16px}

/* секции */
.sec{padding-top:88px;padding-bottom:40px;display:flex;flex-direction:column;gap:28px}
.sec.tight{padding-top:48px;padding-bottom:48px}
.sec h2{font-size:40px;line-height:1.1}
.sec h2 em{font-style:italic;font-weight:600}
.bento{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));grid-auto-rows:minmax(300px,auto);gap:24px}
.card{display:flex;flex-direction:column;text-decoration:none;color:var(--text);background:var(--surface);border-radius:28px;overflow:hidden;box-shadow:var(--shadow);transition:transform .22s ease}
.card:hover{transform:translateY(-3px)}
.card .pic{flex:1;min-height:0;background:var(--window-bg);overflow:hidden}
.card .pic svg{width:100%;height:100%;display:block}
.card .body{padding:24px;display:flex;flex-direction:column;gap:10px;min-width:0;flex:1}
.card h3{font-size:21px;line-height:1.22}
.card .sub{font-size:15px;line-height:1.5;color:var(--sage);font-weight:500;display:-webkit-box;-webkit-box-orient:vertical;-webkit-line-clamp:2;overflow:hidden}
.card .meta{margin-top:auto;font-size:15px;font-weight:500;color:var(--text2)}
.card.big{grid-column:span 2;grid-row:span 2}
.card.big .body{flex:none;padding:24px 28px 28px}
.card.big h3{font-size:30px;line-height:1.15}
.card.wide{grid-column:span 2;flex-direction:row}
.card.wide .pic{flex:none;width:220px}
.chips{display:flex;flex-wrap:wrap;gap:8px;align-items:center}
.chip{align-self:flex-start;background:var(--peach);border-radius:999px;height:32px;padding:0 12px;display:flex;align-items:center;font-size:14px;font-weight:600}
.card.night{background:#241A14;color:#F7EBDD}
.card.night .chip{background:#3D2A20;color:#F7EBDD}
.card.night .sub{color:#9CCB9A}.card.night .meta{color:#D3BFAA}
.rubs{display:flex;gap:20px;flex-wrap:wrap;padding-bottom:6px}
.rub{flex:none;display:flex;flex-direction:column;align-items:center;gap:10px;text-decoration:none;color:var(--text);min-height:48px}
.rub .dot{width:120px;height:120px;border-radius:50%;background:var(--peach);display:flex;align-items:center;justify-content:center;transition:transform .22s ease}
.rub:hover .dot{transform:scale(1.04)}
.rub .dot svg{width:40px;height:40px}
.rub b{font-weight:600;font-size:16px;display:block;text-align:center}
.rub small{font-size:15px;color:var(--text2);display:block;text-align:center}
.sub-block{position:relative;overflow:hidden;background:var(--peach);border-radius:28px;padding:40px 48px;display:flex;flex-wrap:wrap;align-items:center;gap:28px}
.sub-block .t{flex:999 1 320px;display:flex;flex-direction:column;gap:8px}
.sub-block .t b{font:700 40px/1.1 var(--serif);letter-spacing:-.02em}
.sub-block .t b em{font-style:italic}
.sub-block .t span{font-size:17px;color:var(--text2)}
.sub-block .btn{flex:1 1 200px;max-width:260px}

/* подвал */
.foot{background:var(--footer);color:#F7EBDD;margin-top:24px}
.foot a{color:#F7EBDD}
.foot .cols{display:flex;flex-wrap:wrap;gap:40px;justify-content:space-between;padding-top:64px;padding-bottom:40px}
.foot .col{flex:1 1 280px;display:flex;flex-direction:column;gap:14px}
.foot .brand{display:flex;align-items:center;gap:10px;font:700 26px/1 var(--serif);letter-spacing:-.02em}
.foot .brand em{font-style:italic}
.foot .tag{font:italic 500 22px/1.3 var(--serif);color:#D3BFAA}
.foot .sm{font-size:15px;color:#D3BFAA}
.foot nav{flex:1 1 280px;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:4px 24px;font-size:17px;align-content:start}
.foot nav a{min-height:40px;display:flex;align-items:center;text-decoration:none}
.foot nav a:hover{text-decoration:underline}
.foot .bottom{display:flex;flex-wrap:wrap;justify-content:space-between;gap:8px;font-size:15px;color:#D3BFAA;border-top:1px solid rgba(247,235,221,.16);padding-top:18px;padding-bottom:28px}
.foot .bottom a{color:#F5A47E}

.grid3{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:24px}
.card.s .pic{flex:none;height:180px}
.card.s h3{font-size:21px}
.card.big .pic{min-height:0}

/* страница новости */
.article{max-width:760px;margin:0 auto;padding:40px var(--pad) 72px}
.crumbs{display:flex;flex-wrap:wrap;gap:8px 12px;align-items:center;font-size:15px;color:var(--text2)}
.crumbs a{color:var(--text2)}
.article h1{font-size:48px;line-height:1.08;letter-spacing:-.03em;margin:16px 0;text-wrap:balance}
.article .lead{font-size:21px}
.article .window{max-width:none;height:320px;border-radius:160px 160px 28px 28px;margin:32px 0}
.blocks{display:flex;flex-direction:column;gap:16px;margin-top:8px}
.blk{border-radius:24px;padding:24px 28px;background:var(--surface);box-shadow:var(--shadow)}
.blk h2{font-size:24px;margin-bottom:10px}
.blk p{margin:0 0 12px}.blk p:last-child{margin:0}
.blk ul{margin:0;padding-left:1.2em}
.blk.why{background:var(--mint)}
.blk.why h2{color:var(--sage);font-style:italic}
.blk.next{background:var(--peach)}
.sources{margin-top:32px}
.sources h2{font-size:22px;margin-bottom:8px}
.sources ol{margin:0;padding-left:1.2em}
.sources .stamp{color:var(--text2);font-size:15px}
.thanks{margin-top:32px;display:flex;flex-wrap:wrap;align-items:center;gap:16px}
.thanks .t{font-size:15px;color:var(--text2)}
.thanks button.on{background:var(--sage);color:var(--bg)}
.more{display:inline-flex;min-height:48px;align-items:center;font-weight:600}
.preview-bar{margin:16px 0;padding:12px 16px;border-radius:16px;background:var(--peach);font-size:16px}
.page-head{padding-top:40px;padding-bottom:8px}
.page-head h1{font-size:56px;line-height:1.05;letter-spacing:-.03em}
.empty{color:var(--text2)}
.notfound{text-align:center;padding:96px var(--pad) 80px;max-width:720px;margin:0 auto;display:flex;flex-direction:column;align-items:center;gap:20px}
.notfound h1{font-size:44px;line-height:1.1}
.notfound svg{width:160px;height:160px}

/* появление */
@media (prefers-reduced-motion:no-preference){
  .js .reveal{opacity:0;transform:translateY(14px);transition:opacity .4s ease,transform .4s ease}
  .js .reveal.in{opacity:1;transform:none}
  .sky{transition:background .0s}
}
@media (prefers-reduced-motion:reduce){*{transition:none!important;animation:none!important}}

/* телефон */
@media (max-width:759px){
  :root{--pad:20px}
  body{font-size:18px}
  .sun{right:-90px;top:-110px;width:260px;height:260px}
  .mast{padding-top:14px;padding-bottom:14px}
  .nav,.btn-tg{display:none}
  .menu-btn{display:block}
  .nav.open{display:flex;position:fixed;inset:0;z-index:20;background:var(--bg);flex-direction:column;justify-content:center;align-items:center;gap:8px;font-size:26px}
  .hero{gap:24px;padding-top:8px;padding-bottom:40px}
  .window{max-width:none;width:100%;height:200px;border-radius:100px 100px 24px 24px;flex:none}
  .h-display{font-size:34px}
  .lead{font-size:19px}
  .greet{font-size:17px}
  .hero .btn{align-self:stretch;height:56px}
  .strip .wrap{padding-top:24px;padding-bottom:24px;gap:20px}
  .sec{padding-top:48px;padding-bottom:24px}
  .sec.tight{padding-top:32px;padding-bottom:32px}
  .sec h2{font-size:26px}
  .bento,.grid3{display:flex;flex-direction:column;gap:16px}
  .card .pic{flex:none;height:180px}
  .card.big .pic{height:200px}
  .card.big h3{font-size:22px}
  .card.big,.card.wide{border-radius:24px}
  .card.wide{flex-direction:column}
  .card.wide .pic{width:100%;height:140px}
  .rubs{flex-wrap:nowrap;overflow-x:auto;gap:12px}
  .rub{flex-direction:row}
  .rub .dot{width:48px;height:48px}.rub .dot svg{width:22px;height:22px}
  .rub b,.rub small{text-align:left}
  .sub-block{padding:28px 22px}
  .sub-block .t b{font-size:26px}
  .foot .cols{padding-top:40px;padding-bottom:24px}
  .article{padding-top:24px;padding-bottom:56px}
  .article h1{font-size:32px}
  .article .window{height:200px;border-radius:100px 100px 24px 24px}
  .page-head h1{font-size:36px}
}
