/* Simple, senior-friendly entry and route wizard. Added after all theme styles.
 * Keep the Yandex map inside an expandable panel; never cover map controls.
 * The five-tab bottom navigation stays available on EVERY in-app screen,
 * including home and the route builder.
 */
.app[data-rr-screen="home"] .stats-top,.app[data-rr-screen="create"] .stats-top{display:none}
.rr-welcome-screen{max-width:710px;margin:0 auto;padding:clamp(5px,2vh,24px) 0 10px}
/* Home uses the available screen height instead of leaving an unexplained
 * empty band between the primary action and persistent bottom navigation.
 * Normal content flow still scrolls on short phones. */
#home.rr-welcome-screen.active{
 display:flex;flex-direction:column;
 min-height:calc(100dvh - 188px);
}
#home.rr-welcome-screen .rr-welcome-start{
 margin-top:0;
 margin-bottom:8px;
 flex-shrink:0;
}

.rr-home-weather{padding:19px 22px;margin:0 0 18px;border-radius:24px;
 background:linear-gradient(140deg,#283b43,#243a38);color:#f1f7f3;
 border:1px solid #4a625f;box-shadow:0 12px 26px rgba(0,0,0,.14)}
.rr-home-weather-header{display:flex;justify-content:space-between;align-items:center;gap:14px}
.rr-weather-kicker{font-size:12px;letter-spacing:.1em;font-weight:800;color:#c4d8d1}
.rr-home-weather h2{font-size:22px;line-height:1.2;margin:4px 0 0;color:#f3faf5}
.rr-home-weather-header button{min-height:48px;padding:8px 13px;border:1px solid #57776e;
 background:#334b4d;border-radius:13px;color:#e8f7ec;font-weight:800;font-size:14px;cursor:pointer}
.rr-home-weather-value{font-size:clamp(25px,5vw,36px);line-height:1.2;font-weight:900;margin:14px 0 4px;letter-spacing:-.04em}
.rr-home-weather-detail{font-size:15px;line-height:1.5;margin:0;color:#dceae3}
.rr-home-weather-advice{font-size:14px;line-height:1.48;margin:13px 0 0;padding:10px 12px;
 background:rgba(3,17,17,.19);border:1px solid rgba(224,246,237,.14);
 border-radius:12px;color:#e1ece4}
.rr-home-weather-advice[data-severity="critical"]{background:#5c3639;color:#ffe2dc;border-color:#a77977}
.rr-home-weather-advice[data-severity="warn"]{background:#55452d;color:#ffe5b2;border-color:#866b40}
#home.rr-welcome-screen .hero{padding:22px 25px 30px!important;min-height:0!important;margin:0 0 15px}
#home.rr-welcome-screen .hero h1{font-size:clamp(27px,4vw,38px);line-height:1.12;margin:7px 0 10px}
#home.rr-welcome-screen .hero p{font-size:clamp(15px,2vw,17px);line-height:1.5;max-width:510px}
#home.rr-welcome-screen .hero small{font-size:12px;letter-spacing:.08em}
.rr-welcome-mascot{display:flex;align-items:center;min-height:110px;padding:9px 16px!important;
 border:1px solid #59786b!important;border-radius:23px!important;margin:0 0 14px!important}
.rr-welcome-mascot img{width:92px!important;height:100px!important;flex:0 0 92px!important;object-fit:contain}
.rr-welcome-mascot strong{display:block;font-size:clamp(19px,3vw,23px)!important;line-height:1.25}
.rr-welcome-mascot span{font-size:clamp(14px,2vw,16px)!important;line-height:1.48}
.rr-welcome-start{width:100%;min-height:74px!important;border-radius:20px!important;
 display:flex;justify-content:space-between;align-items:center;gap:12px;
 padding:20px 26px!important;font-size:clamp(19px,3vw,23px)!important;
 background:linear-gradient(130deg,#27805f,#1e725d)!important;color:#fff!important;letter-spacing:-.01em}
.rr-welcome-start span{font-size:29px;line-height:1}

/* A permanently visible visual path, including for returning visitors.
 * No saved dismissal state can hide the guide. It takes the existing free
 * space between Marshik and CTA without covering taps or bottom navigation. */
#home .rr-welcome-mascot{position:relative}
#home .rr-welcome-mascot .rr-marshik-pointing-hand{
  position:absolute;left:clamp(42px,9%,65px);bottom:-13px;z-index:2;
  transform:rotate(-16deg);font-size:29px!important;line-height:1!important;
  filter:drop-shadow(0 2px 3px rgba(0,0,0,.6));pointer-events:none;
}
#home .rr-marshik-pointer{
  position:relative;display:block;flex:1 0 32px;min-height:32px;
  margin:0 0 8px;pointer-events:none;
}
#home .rr-marshik-pointer-svg{
  display:block;position:absolute;inset:0;width:100%;height:100%;
  overflow:visible;filter:drop-shadow(0 0 4px rgba(255,202,90,.8));
  animation:rrMarshikPoint 1.5s ease-in-out 3;
}
#home .rr-marshik-pointer-line,
#home .rr-marshik-pointer-tip{
  fill:none;stroke:#ffe38a;stroke-width:6;stroke-linecap:round;stroke-linejoin:round;
  vector-effect:non-scaling-stroke;
}
#home .rr-marshik-pointer-tip{stroke-width:7}
#home #homeOpenCreateBtn.rr-marshik-cta-active{
  position:relative;z-index:1;
  outline:3px solid #ffe08a;outline-offset:2px;
  box-shadow:0 0 0 5px rgba(255,216,126,.35),0 0 30px rgba(255,213,111,.55),0 12px 28px rgba(0,0,0,.25)!important;
  animation:rrMarshikCtaPulse 1.8s ease-in-out 3;
}
#home #homeOpenCreateBtn.rr-marshik-cta-active::after{
  content:"";position:absolute;inset:-6px;border:2px solid #ffe29a;
  border-radius:25px;pointer-events:none;animation:rrMarshikRing 1.8s ease-out 3;
}
@keyframes rrMarshikPoint{
  0%,100%{opacity:1}
  50%{opacity:.65}
}
@keyframes rrMarshikCtaPulse{
  0%,100%{transform:scale(1)}
  50%{transform:scale(1.02)}
}
@keyframes rrMarshikRing{
  0%{opacity:.85;transform:scale(1)}
  100%{opacity:0;transform:scale(1.045)}
}
@media(prefers-reduced-motion:reduce){
  #home .rr-marshik-pointer-svg,
  #home #homeOpenCreateBtn.rr-marshik-cta-active,
  #home #homeOpenCreateBtn.rr-marshik-cta-active::after{animation:none!important}
}
.rr-create-screen{max-width:830px;margin:0 auto;padding:2px 0 20px}
.rr-create-back{display:inline-block;min-height:49px;padding:12px 15px;margin:2px 0 16px;
 border:1px solid #536c62;background:#2b3e42;color:#e6f5eb;border-radius:14px;
 font-weight:800;font-size:15px;cursor:pointer}
.rr-create-heading{margin:0 0 21px}
.rr-create-heading>span{font-size:12px;letter-spacing:.12em;color:#8dc7ae;font-weight:900}
.rr-create-heading h1{font-size:clamp(27px,4vw,36px);line-height:1.12;margin:6px 0 9px;color:var(--ink)}
.rr-create-heading p{font-size:16px;line-height:1.52;max-width:600px;color:var(--muted);margin:0}
.rr-create-panel{margin:0 0 14px;padding:20px 21px;border-radius:23px;
 background:linear-gradient(152deg,#29363d,#243036);border:1px solid #475b58;color:#eaf4ed;
 box-shadow:0 8px 25px rgba(0,0,0,.11)}
.rr-create-panel h2{display:flex;align-items:center;gap:12px;font-size:clamp(18px,2.7vw,22px);
 font-weight:850;line-height:1.35;margin:0 0 16px;color:#eaf5ee}
.rr-create-step-number{background:#2f7559;display:grid;place-items:center;color:#f4fff7;font-size:17px;
 border-radius:50%;width:36px;height:36px;min-width:36px}
.rr-distance-options{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:11px}
.rr-distance-options button{display:flex;flex-direction:column;justify-content:center;align-items:flex-start;
 min-height:81px;padding:14px 17px;border-radius:17px;background:#35434a;color:#f0f7f1;
 border:2px solid #53655f;text-align:left;cursor:pointer}
.rr-distance-options button strong{font-size:23px;font-weight:900;line-height:1.2}
.rr-distance-options button small{font-size:13px;color:#c3d5cb;line-height:1.45;margin-top:5px}
.rr-distance-options button.active,.rr-distance-options button[aria-pressed="true"]{background:#244d40;border-color:#76ce9b;box-shadow:inset 0 0 0 1px #76ce9b}
.rr-distance-options button[aria-pressed="true"]:before{content:"✓ Выбрано";font-size:12px;font-weight:800;color:#a8f0c6;margin-bottom:2px}
.rr-wish-buttons{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:11px}
.rr-wish-buttons button{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:8px;
 min-height:118px;padding:12px 8px!important;border-radius:18px!important;
 border:2px solid #53655f!important;background:#35434a!important;color:#e6f4ea!important;cursor:pointer}
.rr-wish-buttons button span{font-size:32px!important;margin:0!important}
.rr-wish-buttons button b{font-size:15px;line-height:1.4;font-weight:850}
.rr-wish-buttons button.active,.rr-wish-buttons button[aria-pressed="true"]{background:#245445!important;border-color:#79d4a3!important;color:#d7ffe4!important;box-shadow:inset 0 0 0 1px #79d4a3!important}
.rr-create-intro{font-size:16px;line-height:1.55;color:#d6e7db;margin:0 0 12px}
/* GPS is advanced configuration, not a mandatory full-screen third card.
 * All location controls and map exclusions remain available inside details. */
#rrStartSettings.rr-create-start-compact{
 margin:0 0 12px;border:1px solid #475b58;border-radius:17px;
 background:#29363d;color:#eaf5ee;box-shadow:none;overflow:visible
}
#rrStartSettings.rr-create-start-compact>summary{
 display:flex;align-items:center;gap:8px;min-height:54px;
 padding:12px 15px;font-size:15px;line-height:1.25;list-style:none
}
#rrStartSettings.rr-create-start-compact>summary .rr-start-summary-heading{flex:1}
#rrStartSettings.rr-create-start-compact>summary .rr-start-summary-note{
 flex:0 1 auto;min-width:0;font-size:12px;font-weight:600;color:#b9cfc2
}
#rrStartSettings.rr-create-start-compact>summary::after{position:static;flex:0 0 auto;margin-left:4px}
#rrStartSettings .rr-start-settings-body{padding:0 14px 14px}
#rrStartSettings .rr-create-intro{font-size:14px;line-height:1.45}
#rrStartSettings .location-status{border-radius:12px;padding:11px 12px;font-size:13px}
#rrStartSettings .gps-quality{font-size:12px;margin:8px 0}
#rrStartSettings .rr-create-gps-actions{margin:10px 0 0}
#rrStartSettings .rr-create-gps-actions button{min-height:48px}
#rrStartSettings .rr-map-details{margin:12px 0 0}
@media(max-width:599px){
 #rrStartSettings.rr-create-start-compact>summary{min-height:52px;padding:12px}
 #rrStartSettings .rr-start-settings-body{padding:0 12px 12px}
 #rrStartSettings.rr-create-start-compact>summary .rr-start-summary-note{font-size:11px}
}
html[data-rr-theme="light"] #rrStartSettings.rr-create-start-compact{
 background:#fff;color:#163e2d;border-color:#d6e5dc
}
html[data-rr-theme="light"] #rrStartSettings .rr-start-summary-note{color:#54705e}
.rr-create-note{font-size:14px;line-height:1.55;color:#bacdc1;margin:12px 0 0}
.rr-create-field-label{display:block;font-size:15px;font-weight:700;color:#d3e8da;margin:12px 0 8px}
.rr-create-details{margin:13px 0 0;border-radius:16px;border:1px solid #52645d;
 background:#2c3b41;color:#e5f3eb;overflow:hidden}
.rr-create-details>summary{cursor:pointer;list-style:none;display:flex;align-items:center;gap:8px;
 padding:14px 16px;min-height:52px;font-size:15px;line-height:1.45;font-weight:800}
.rr-create-details>summary::-webkit-details-marker{display:none}
.rr-create-details>summary:after{content:"⌄";margin-left:auto;font-size:22px;line-height:1}
.rr-create-details[open]>summary:after{content:"⌃"}
.rr-create-details>summary:focus-visible{outline:3px solid #7de0ad;outline-offset:-3px}
.rr-create-details .distance-wrap,.rr-create-details .rr-create-field-label{margin-left:16px;margin-right:16px}
.rr-create-details .distance-wrap{margin-bottom:16px}
.rr-create-details .distance{background:#202d34;color:#e8f2ed;border-color:#5a766b;font-size:20px}
.rr-create-details .unit{color:#d6e7dc}
.rr-create-gps-actions{display:flex;gap:10px;flex-wrap:wrap;margin:13px 0 0}
.rr-create-gps-actions button{flex:1;min-width:170px;min-height:55px;border-radius:15px;font-size:15px}
.rr-create-panel .location-status{border-radius:14px;padding:13px 15px;font-size:15px;line-height:1.45}
.rr-create-panel .gps-quality{font-size:13px;margin:11px 0}
.rr-map-inner{padding:0 13px 12px}
.rr-map-inner #homeMap{height:260px;min-height:240px}
.rr-map-details .avoid-card{margin:7px 10px 12px}
.rr-map-details .map-credit{font-size:12px}
.rr-more-wishes{margin-bottom:17px}
.rr-extra-wishes{padding:3px 17px 17px}
.rr-extra-wishes p{font-size:14px;line-height:1.5;color:#c1d2c8;margin:0 0 15px}
.rr-extra-wishes .row{font-size:16px;font-weight:800}
.rr-extra-wishes .toggle{flex:0 0 48px}
.rr-create-go{min-height:72px!important;border-radius:19px!important;font-size:clamp(18px,3vw,21px)!important;
 display:flex;align-items:center;justify-content:space-between;padding:19px 22px!important}
.rr-create-go span{font-size:27px}
.rr-create-final-note{font-size:14px;line-height:1.55;color:var(--muted);margin:11px 4px 18px}
.rr-daily-details{margin-top:12px}
.rr-daily-details #rrDailyCreateMount{padding:0 10px 10px}
.rr-daily-details .rdq-card{margin:0}
.rr-welcome-screen button:focus-visible,.rr-create-screen button:focus-visible{
 outline:3px solid #7de0ad!important;outline-offset:3px!important}
@media(hover:hover){
 .rr-distance-options button:hover,.rr-wish-buttons button:hover{border-color:#8ed9ae!important}
}
@media(max-width:599px){
 .rr-welcome-screen{padding:4px 0 0}
 #home.rr-welcome-screen.active{min-height:calc(100dvh - 175px)}
 #home.rr-welcome-screen .rr-welcome-start{margin-bottom:5px}
 .rr-home-weather{padding:16px 17px;margin-bottom:13px;border-radius:20px}
 .rr-home-weather-value{font-size:27px;margin-top:12px}
 .rr-home-weather-header h2{font-size:19px}
 .rr-home-weather-header button{font-size:13px;padding:8px 10px}
 #home.rr-welcome-screen .hero{padding:20px 18px 39px!important;margin-bottom:13px}
 #home.rr-welcome-screen .hero h1{font-size:28px}
 .rr-welcome-mascot{min-height:105px;padding:9px 12px!important;gap:10px!important;margin-bottom:15px!important}
 .rr-welcome-mascot img{width:78px!important;height:100px!important;flex:0 0 78px!important}
 .rr-welcome-mascot strong{font-size:18px!important}
 .rr-welcome-mascot span{font-size:14px!important}
 .rr-welcome-start{min-height:68px!important;font-size:20px!important;padding:17px 20px!important}
 .rr-create-panel{padding:17px 15px;border-radius:20px}
 .rr-wish-buttons{gap:7px}
 .rr-wish-buttons button{min-height:105px;padding:9px 3px!important}
 .rr-wish-buttons button b{font-size:13px}
 .rr-wish-buttons button span{font-size:27px!important}
 .rr-distance-options button{padding:12px;min-height:80px}
 .rr-distance-options button strong{font-size:22px}
 .rr-distance-options button small{font-size:12px}
}
@media(max-width:350px){
 .rr-wish-buttons{grid-template-columns:1fr}
 .rr-wish-buttons button{min-height:60px;flex-direction:row;gap:12px}
 .rr-wish-buttons button span{font-size:24px!important}
 .rr-create-panel h2{font-size:18px}
}
@media(prefers-reduced-motion:reduce){
 .rr-welcome-screen *,.rr-create-screen *{scroll-behavior:auto!important;transition:none!important}
}
/* Light theme remains readable when the user chooses it. */
html[data-rr-theme="light"] .rr-home-weather{background:linear-gradient(140deg,#dcebe3,#e4edf0);color:#173e32;border-color:#c4dacd}
html[data-rr-theme="light"] .rr-home-weather h2,
html[data-rr-theme="light"] .rr-home-weather-value{color:#173e32}
html[data-rr-theme="light"] .rr-weather-kicker,
html[data-rr-theme="light"] .rr-home-weather-detail{color:#36574b}
html[data-rr-theme="light"] .rr-home-weather-header button{background:#f7faf8;color:#204c39;border-color:#aecbbb}
html[data-rr-theme="light"] .rr-home-weather-advice{background:#edf4ef;color:#385b4b;border-color:#c5dbd0}
html[data-rr-theme="light"] .rr-create-panel{background:#fff;border-color:#d6e5dc;color:#163e2d}
html[data-rr-theme="light"] .rr-create-panel h2{color:#163e2d}
html[data-rr-theme="light"] .rr-create-back,
html[data-rr-theme="light"] .rr-create-details{background:#eff6f2;color:#194d35;border-color:#cedfd3}
html[data-rr-theme="light"] .rr-create-intro{color:#375a47}
html[data-rr-theme="light"] .rr-create-note,
html[data-rr-theme="light"] .rr-extra-wishes p,
html[data-rr-theme="light"] .rr-create-field-label{color:#49695a}
html[data-rr-theme="light"] .rr-distance-options button,
html[data-rr-theme="light"] .rr-wish-buttons button{background:#f4f9f6!important;color:#143f2b!important;border-color:#bfd6c7!important}
html[data-rr-theme="light"] .rr-distance-options button small{color:#587766}
html[data-rr-theme="light"] .rr-distance-options button.active,
html[data-rr-theme="light"] .rr-wish-buttons button.active{background:#e0f5e9!important;border-color:#39976c!important;color:#165538!important}
html[data-rr-theme="light"] .rr-distance-options button[aria-pressed="true"]:before{color:#165538}
html[data-rr-theme="light"] .rr-create-details .distance{background:#fff;color:#1b402f}
html[data-rr-theme="light"] .rr-create-details .unit{color:#3b5f4e}

/* The forecast now has its own card; do not duplicate weather text over the headline. */
#home.rr-welcome-screen .rr-weather-label{display:none!important}

/* Route generation feedback: calm, visible and screen-reader accessible. */
.rr-build-status{
  margin:10px 0 6px;padding:13px 15px;border-radius:15px;
  border:1px solid #506f65;background:rgba(34,66,61,.90);
  color:#dcefe5;font-size:15px;line-height:1.48;font-weight:750;
}
.rr-build-status[hidden]{display:none!important}
.rr-build-status[data-state="error"]{
  border-color:#e1b76a;background:#333c38;color:#ffedc4;
}
#routeBuildStatus[data-state="error"]{margin-top:10px}
#buildBtn[aria-describedby="routeBuildStatus"]{outline:3px solid #efc16c;outline-offset:3px}
#tryDemoRouteBtn.rr-demo-recovery{
  min-height:48px;margin:8px 0 12px;border-color:#9fd5be;
  background:#23443b;color:#e4fff0;font-size:14px;
}
html[data-rr-theme="light"] #tryDemoRouteBtn.rr-demo-recovery{
  background:#ebf8f0;border-color:#a8d4bb;color:#154d31;
}
html[data-rr-theme="light"] .rr-build-status[data-state="error"]{
  background:#fff2d7;color:#6a421e;border-color:#e1b76a;
}
#buildBtn:disabled{cursor:progress;opacity:.78}
html[data-rr-theme="light"] .rr-build-status{
  background:#eaf5ef;border-color:#b9d8c8;color:#27553f;
}
@media (prefers-reduced-motion: reduce){.rr-build-status{transition:none!important}}

/* The welcome screen handles first-visit authentication.
   Existing guests can choose to sign in from their profile, not home. */
#profile .rr-guest-signin{
 display:block;width:100%;min-height:48px;margin:0 0 12px;padding:11px 14px;
 border-radius:14px;border:1px solid #7fae9d;
 background:#2a5148;color:#ecfff4;font-size:14px;font-weight:850;cursor:pointer;
}
#profile .rr-guest-signin.hidden{display:none!important}
#profile .rr-guest-signin:focus-visible{outline:3px solid #fbdc8f;outline-offset:3px}
.rr-guest-profile-notice{
 padding:13px 15px!important;margin:0 0 12px!important;
 border:1px solid #7ab29c!important;border-radius:15px!important;
 color:#e8fff2!important;background:#285047!important;
 font-size:13px!important;line-height:1.5!important
}
html[data-rr-theme="light"] .rr-guest-profile-notice{
 color:#174838!important;background:#e7f6ee!important;border-color:#a6c9b7!important
}
@media(max-width:599px){
 #profile .rr-guest-signin{min-height:52px;font-size:15px}
}
