/* Worldview — stil inspirat din identitatea vizuală Cru (varianta E: bleumarin + galben) */
:root{color-scheme:dark;
  --navy:#1F1F47; --navy2:#27275A; --line:#3A3A72; --deep:#14142F;
  --yellow:#FFD000; --cyan:#00C0D8; --teal:#007890; --orange:#F08020; --mint:#88E4B6;
  --white:#FFFFFF; --black:#000000;
  --fh:"Sora","Inter",system-ui,sans-serif; --fb:"Inter",system-ui,sans-serif;
  --f0:var(--cyan); --f1:var(--yellow); --f2:var(--orange); --f3:var(--mint);
}
html[lang=ru],html[lang=uk],html[lang=bg]{--fh:"Inter",system-ui,sans-serif}
*{box-sizing:border-box}
html{-webkit-text-size-adjust:100%}
body{margin:0;background:var(--deep);color:var(--white);font:16px/1.5 var(--fb);min-height:100vh}
#app{max-width:560px;margin:0 auto;min-height:100vh;background:var(--navy);position:relative;overflow-x:hidden}
#app.wide{max-width:1180px}
a{color:var(--white)}
button{font:inherit;color:inherit;cursor:pointer}
:focus-visible{outline:3px solid var(--yellow);outline-offset:3px}
[hidden]{display:none!important}
.sr{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0 0 0 0);white-space:nowrap}
h1,h2,h3{font-family:var(--fh);margin:0}
.light{font-weight:300}
.y{color:var(--yellow)}

/* top bar */
.top{position:relative;z-index:2;display:flex;justify-content:space-between;align-items:center;gap:12px;padding:16px 20px}
.brand{font:700 15px var(--fh);letter-spacing:.14em;text-decoration:none}
.iconbtn{display:inline-flex;align-items:center;justify-content:center;min-width:44px;height:44px;border:1.5px solid var(--white);background:transparent;padding:0 12px;gap:6px;font-weight:600;font-size:14px;text-decoration:none}
.iconbtn svg{width:20px;height:20px;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:square}

/* buttons */
.btn{display:flex;align-items:center;justify-content:space-between;gap:12px;width:100%;min-height:58px;padding:0 22px;border:0;font:600 18px var(--fh);text-decoration:none;text-align:left}
.btn svg{width:24px;height:24px;flex:none;fill:none;stroke:currentColor;stroke-width:2.2;stroke-linecap:square}
.btn.primary{background:var(--yellow);color:var(--black)}
.btn.primary:hover{background:#FFE14D}
.btn.outline{background:transparent;color:var(--white);border:1.5px solid var(--white);min-height:50px;font:600 15px var(--fb);justify-content:center}
.btn.outline:hover{background:rgba(255,255,255,.08)}
.btn.small{min-height:44px;font-size:14px;width:auto}
.link{display:inline-flex;align-items:center;min-height:44px;font-weight:600;font-size:15px}
.stack{display:flex;flex-direction:column;gap:10px}

/* home */
.home{min-height:100vh;display:flex;flex-direction:column;position:relative}
.hero{position:absolute;left:0;top:0;width:100%;height:55vh;max-height:520px;object-fit:cover;object-position:center 30%}
.hero-fade{position:absolute;left:0;right:0;top:calc(min(55vh,520px) - 120px);height:121px;background:linear-gradient(rgba(31,31,71,0),var(--navy))}
.home-body{position:relative;margin-top:auto;padding:24px 20px 32px;display:flex;flex-direction:column;gap:18px}
.h-xl{font-weight:700;font-size:clamp(38px,11vw,48px);line-height:1.06;letter-spacing:-.02em;color:var(--yellow)}
.lead{font-size:17px;margin:0}
.home .small-actions{display:flex;justify-content:space-between;flex-wrap:wrap;gap:4px}

/* guided */
.q-head{position:relative;height:150px}
.q-head img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.q-head .top{padding-top:14px}
.prog{flex:1;display:grid;gap:4px}
.prog span{height:6px;background:rgba(255,255,255,.25)}
.prog span.on{background:var(--yellow)}
.prog span i{display:block;height:6px;background:var(--yellow)}
.count{font:600 14px var(--fh);min-width:44px;text-align:right}
.q-body{padding:18px 20px 28px;display:flex;flex-direction:column;min-height:calc(100vh - 150px)}
.dom{font-size:13px;font-weight:600;letter-spacing:.06em;text-transform:uppercase}
.q-title{margin-top:8px;font-weight:700;font-size:clamp(24px,7vw,30px);line-height:1.15;color:var(--yellow)}
.note{border-left:4px solid var(--cyan);padding:8px 12px;margin:14px 0 0;font-size:14px;background:rgba(0,192,216,.08)}
.opt{margin-top:18px;border:1.5px solid var(--cyan);padding:14px 16px;display:flex;flex-direction:column;gap:4px}
.opt b{font:700 14px var(--fh)}
.opt.b{border-color:var(--yellow)}
.opt.b b{color:var(--yellow)}
.opt p{margin:0;font-size:16px;line-height:1.45}
.opt.sel{background:rgba(255,255,255,.06)}
.scale{margin-top:18px;display:flex;justify-content:space-between;align-items:center}
.dot{position:relative;display:flex;align-items:center;justify-content:center;width:44px;height:48px;cursor:pointer}
.dot input{position:absolute;inset:0;opacity:0;margin:0;cursor:pointer}
.dot span{display:block;border:2px solid var(--c);transition:transform .12s,background .12s}
.dot.s0 span,.dot.s6 span{width:40px;height:40px}.dot.s1 span,.dot.s5 span{width:34px;height:34px}.dot.s2 span,.dot.s4 span{width:28px;height:28px}.dot.s3 span{width:22px;height:22px}
.dot.s0,.dot.s1,.dot.s2{--c:var(--cyan)}.dot.s4,.dot.s5,.dot.s6{--c:var(--yellow)}.dot.s3{--c:#9A9AC4}
.dot:hover span{transform:scale(1.1)}
.dot input:checked+span{background:var(--c)}
.dot input:focus-visible+span{outline:3px solid var(--white);outline-offset:3px}
.scale-lab{margin-top:8px;text-align:center;font-weight:600;font-size:14px;min-height:21px}
.q-tools{margin-top:16px;display:flex;gap:14px;flex-wrap:wrap;align-items:center}
.chip{min-height:44px;border:1.5px solid var(--white);background:transparent;padding:0 14px;font-weight:600;font-size:14px}
.chip[aria-pressed=true]{background:var(--white);color:var(--navy)}
details.explain summary{cursor:pointer;font-weight:600;font-size:14px;text-decoration:underline;min-height:44px;display:flex;align-items:center;list-style:none}
details.explain summary::-webkit-details-marker{display:none}
details.explain p{margin:4px 0 0;font-size:14px;line-height:1.5}
.q-next{margin-top:auto;padding-top:22px}
.mc{display:flex;flex-direction:column;gap:8px;margin-top:20px}
.mc label{display:flex;gap:12px;align-items:flex-start;padding:14px 16px;border:1.5px solid var(--line);cursor:pointer;font-size:16px;line-height:1.4}
.mc label:has(input:checked){border-color:var(--yellow);background:rgba(255,208,0,.1)}
.mc input{accent-color:var(--yellow);width:20px;height:20px;margin:1px 0 0;flex:none}

/* result */
.res{padding:4px 20px 36px;display:flex;flex-direction:column;gap:22px}
.rcard{background:var(--yellow);color:var(--black);position:relative;overflow:hidden}
.rcard img{display:block;width:100%;height:170px;object-fit:cover;object-position:center 62%}
.rcard .in{padding:16px 20px 22px;display:flex;flex-direction:column;gap:6px}
.rcard .corner{position:absolute;right:14px;bottom:14px;width:30px;height:30px;border-right:7px solid #000;border-bottom:7px solid #000}
.kicker{font-size:12px;font-weight:600;letter-spacing:.07em;text-transform:uppercase}
.rcard h1{font-weight:700;font-size:clamp(28px,8vw,34px);line-height:1.08;letter-spacing:-.01em}
.pct-big{font:700 34px var(--fh)}
.fam{display:flex;align-items:center;gap:8px;font-size:14px}
.sec h3{font-weight:600;font-size:18px;margin-bottom:10px}
.sec>p{margin:0 0 10px;font-size:15px}
.bars{display:flex;flex-direction:column;gap:10px}
.bar{display:grid;grid-template-columns:minmax(0,1fr) 34% 42px;gap:10px;align-items:center;font-size:14px}
.bar .t{height:8px;background:var(--line)}.bar .t i{display:block;height:8px;background:var(--fc,var(--cyan))}
.bar b{text-align:right;font-weight:600}
.quote{border-left:5px solid var(--yellow);background:var(--navy2);padding:12px 14px;font-size:15px;line-height:1.45;margin:0 0 8px}
.pdom h4{font:600 15px var(--fh);color:var(--yellow);margin:14px 0 8px}
.pdom ul{list-style:none;margin:0;padding:0}
.pdom li{background:var(--navy2);border-left:5px solid var(--c);padding:10px 12px;margin-bottom:6px;line-height:1.4;font-size:15px}
.pdom li.a{--c:var(--cyan)}.pdom li.b{--c:var(--yellow)}
.pdom li .lv{display:block;font-size:11px;font-weight:600;letter-spacing:.07em;text-transform:uppercase}
ul.plain{margin:0;padding-left:20px}ul.plain li{margin:5px 0}
.card{background:var(--navy2);border:1px solid var(--line);padding:16px}
details.more>summary{cursor:pointer;font:600 17px var(--fh);min-height:48px;display:flex;align-items:center;justify-content:space-between;list-style:none}
details.more>summary::-webkit-details-marker{display:none}
details.more>summary::after{content:"+";font-size:24px;font-weight:300}
details.more[open]>summary::after{content:"–"}
.toast{position:fixed;left:50%;bottom:24px;transform:translateX(-50%);background:var(--white);color:var(--navy);padding:10px 16px;font-weight:600;z-index:50}
.cmrow{display:grid;grid-template-columns:1fr 2em;gap:4px 10px;align-items:center;margin:8px 0;font-size:14px}
.cmrow input{grid-column:1/-1;width:100%;accent-color:var(--yellow);min-height:28px}
.cmrow output{text-align:right;font-weight:600}

/* icons */
.ic{display:inline-flex;align-items:center;justify-content:center;flex:none;width:28px;height:28px;color:var(--fc,currentColor)}
.ic svg{width:100%;height:100%;fill:none;stroke:currentColor;stroke-width:2.6;stroke-linecap:round;stroke-linejoin:round}
.rcard .ic{color:#000}
.f0{--fc:var(--f0)}.f1{--fc:var(--f1)}.f2{--fc:var(--f2)}.f3{--fc:var(--f3)}

/* expert */
.exp{padding:0 20px 120px}
.exp-intro{max-width:70ch;font-size:15px}
.switch{display:flex;align-items:center;gap:12px;border:1.5px solid var(--white);padding:12px 14px;margin:14px 0;cursor:pointer}
.switch input{width:22px;height:22px;accent-color:var(--yellow);margin:0}
.switch span{flex:1}.switch small{display:block;font-size:13px}
.grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;align-items:start}
@media(max-width:860px){.grid{grid-template-columns:1fr}}
.dcard{background:var(--navy2);border:1px solid var(--line);padding:14px}
.dcard h2{font-weight:600;font-size:19px;color:var(--yellow)}
.dcard svg.radar{display:block;width:100%;max-width:420px;height:auto;margin:6px auto}
.radar text{font:11px var(--fb);fill:var(--white)}
.radar .ring{fill:none;stroke:var(--line)}.radar .spoke{stroke:var(--line)}
.radar .poly{fill:rgba(0,192,216,.18);stroke:var(--cyan);stroke-width:2.2;stroke-linejoin:round}
.radar .proto{fill:none;stroke:var(--yellow);stroke-width:2;stroke-dasharray:7 5}
.arow{padding:12px 0;border-top:1px solid var(--line)}
.arow .h{display:flex;justify-content:space-between;gap:8px;align-items:baseline}
.arow .h b{font:600 15px var(--fh)}
.arow .v{font-weight:600;min-width:2.5em;text-align:right}
.poles{display:grid;grid-template-columns:1fr 1.4fr 1fr;gap:8px;align-items:center;margin-top:6px;font-size:13px;line-height:1.25}
.poles .l{text-align:right;color:var(--cyan)}.poles .r{color:var(--yellow)}
.poles input{width:100%;accent-color:var(--yellow);min-height:30px}
@media(max-width:520px){.poles{grid-template-columns:1fr 1fr}.poles input{grid-column:1/-1;order:3}}
.arow .tools{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin-top:4px}
.arow .tools label{display:flex;gap:6px;align-items:center;font-size:13px;min-height:36px;cursor:pointer}
.arow .tools input{accent-color:var(--yellow);width:18px;height:18px}
.arow details summary{font-size:13px;text-decoration:underline;cursor:pointer;min-height:36px;display:flex;align-items:center}
.arow details p{font-size:13px;margin:4px 0 0}
.arow.off .poles{opacity:.4}
.sticky-go{position:fixed;left:0;right:0;bottom:0;padding:12px 20px calc(12px + env(safe-area-inset-bottom));background:var(--deep);border-top:1px solid var(--line);z-index:10}
.sticky-go .btn{max-width:520px;margin:0 auto}

/* library */
.lib{padding:0 20px 36px}
.fbox{border-top:4px solid var(--fc);background:var(--navy2);margin:18px 0;padding:14px 16px}
.fbox h2{font-weight:600;font-size:19px;color:var(--fc)}
.fbox>p{font-size:14px;margin:6px 0 4px}
.fbox h3{font:600 14px var(--fb);margin:12px 0 2px;text-transform:uppercase;letter-spacing:.05em}
.pitem{border-top:1px solid var(--line)}
.pitem summary{display:flex;align-items:center;gap:10px;min-height:52px;cursor:pointer;list-style:none;font-weight:600}
.pitem summary::-webkit-details-marker{display:none}
.pitem summary small{margin-left:auto;font-weight:400;font-size:13px}
.pitem p{font-size:15px;margin:0 0 10px}

/* dialog */
.sheet{position:fixed;inset:0;background:rgba(0,0,0,.6);z-index:40;display:flex;align-items:flex-end;justify-content:center}
.sheet .panel{background:var(--navy);width:100%;max-width:560px;padding:20px 20px calc(24px + env(safe-area-inset-bottom));border-top:4px solid var(--yellow)}
.sheet h2{font-size:20px;margin-bottom:12px}
.sheet .langs{display:flex;flex-direction:column;gap:8px}
.sheet .langs button{min-height:52px;text-align:left;padding:0 16px;border:1.5px solid var(--line);background:transparent;font-weight:600;font-size:16px}
.sheet .langs button[aria-current=true]{border-color:var(--yellow);color:var(--yellow)}

@media print{.top,.btn,.sticky-go,details.more>summary::after{display:none!important}body,#app{background:#fff;color:#000}}
.q-head .count{background:var(--navy);padding:6px 8px}
.q-head .iconbtn{background:var(--navy)}
.q-head::after{content:"";position:absolute;inset:0;background:rgba(20,20,47,.25);pointer-events:none}
.q-head .top{z-index:3}
.q-title:focus{outline:none}
.toast{max-width:90vw;text-align:center}

/* ===== Ecran mare (laptop, calculator): tot ecranul ===== */
.res-side{display:flex;flex-direction:column;gap:16px}
.res-main{display:flex;flex-direction:column;gap:22px;min-width:0}
@media (min-width:900px){
  #app,#app.wide{max-width:none}
  body{background:var(--navy)}
  .v-q .top,.v-res .top,.v-lib .top,.v-exp .top{max-width:1180px;margin:0 auto;padding:20px 40px}
  /* start */
  .v-home .top{padding:24px 48px}
  .v-home .hero{height:100vh;max-height:none;object-position:center 40%}
  .v-home .hero-fade{top:auto;bottom:0;height:45vh;background:linear-gradient(rgba(31,31,71,0),rgba(31,31,71,.9))}
  .v-home .home::before{content:"";position:absolute;inset:0;background:linear-gradient(90deg,rgba(20,20,47,.75),rgba(20,20,47,0) 60%);z-index:1}
  .v-home .hero-fade{z-index:1}
  .v-home .home-body{z-index:2;max-width:640px;padding:0 48px 72px;gap:22px}
  .v-home .h-xl{font-size:clamp(52px,5.4vw,76px)}
  .v-home .lead{font-size:19px;max-width:48ch}
  .v-home .stack{flex-direction:row;flex-wrap:wrap}
  .v-home .stack .btn{width:auto;flex:1 1 220px}
  /* întrebare */
  .v-q .q-head{height:200px}
  .v-q .q-head .top{max-width:860px;margin:0 auto;padding:20px 40px}
  .v-q .q-body{max-width:860px;margin:0 auto;padding:32px 40px 48px;min-height:calc(100vh - 200px)}
  .v-q .q-title{font-size:36px}
  .v-q .opt p{font-size:18px}
  .v-q .scale{max-width:560px;margin-left:auto;margin-right:auto;width:100%}
  .v-q .dot{width:56px;height:56px}
  .v-q .q-next .btn{max-width:360px;margin-left:auto}
  .v-q .mc{display:grid;grid-template-columns:repeat(2,minmax(0,1fr))}
  /* rezultat */
  .v-res .res{max-width:1180px;margin:0 auto;padding:8px 40px 56px;display:grid;grid-template-columns:400px minmax(0,1fr);gap:48px;align-items:start}
  .v-res .res-side{position:sticky;top:24px}
  .v-res .rcard img{height:220px}
  .pgrid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 24px;align-items:start}
  /* perspective */
  .v-lib .lib{max-width:1180px;margin:0 auto;padding:0 40px 56px}
  .fgrid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:0 24px;align-items:start}
  /* expert */
  .v-exp .exp{max-width:1180px;margin:0 auto;padding:0 40px 120px}
}
@media (min-width:1400px){
  .v-res .res{grid-template-columns:440px minmax(0,1fr)}
}
