/* Only additions for authentication, personal account and the heart icon. */
[hidden]{display:none!important}
.preview-actions{display:flex;flex-direction:column;align-items:flex-end;gap:8px}
.tw-icon-defs{position:absolute;width:0;height:0;overflow:hidden;pointer-events:none}
.tw-icon{width:26px;height:26px;display:block;flex:none;fill:none;stroke:currentColor;stroke-width:1.7;stroke-linecap:round;stroke-linejoin:round}
.tw-icon-button{display:inline-flex;align-items:center;justify-content:center;width:44px;height:44px;flex:none;padding:9px;border:0;border-radius:12px;background:transparent;color:var(--mu);cursor:pointer;font:inherit}
.tw-icon-button:hover{color:var(--ac);background:var(--acs)}
.tw-account-icon{order:10;display:inline-flex;align-items:center;justify-content:center;width:44px;height:40px;min-width:44px;min-height:0;padding:3px;color:var(--tx)}
.tw-account-icon .tw-icon{width:28px;height:28px}
.tw-account-icon.is-logged-in{color:var(--ac)}
.tw-plan-heading{display:flex;align-items:center;justify-content:space-between;gap:16px}
#tw-heart{color:var(--mu)}
#tw-heart .tw-icon{width:27px;height:27px}
#tw-heart[aria-pressed="true"]{color:#d5294f}
#tw-heart[aria-pressed="true"] .tw-icon{fill:currentColor}
#tw-heart:hover{color:#d5294f;background:#fff0f3}
.preview-map{height:100%;display:flex;flex-direction:column;align-items:center;justify-content:center;gap:12px;color:var(--mu);background:var(--card2);padding:24px;text-align:center}
.preview-map small{font-size:12px;max-width:220px}
.tw-page{gap:22px;padding-top:32px}
.tw-eyebrow{font-family:'JetBrains Mono',monospace;font-size:11px;letter-spacing:.14em;color:var(--ac)}
.tw-muted{color:var(--mu)}.tw-small{font-size:12px}
.tw-profile-head{display:flex;align-items:center;gap:20px;flex-wrap:wrap}.tw-profile-head h1{font-size:32px;overflow-wrap:anywhere}
.tw-avatar{width:60px;height:60px;border-radius:16px;background:var(--acs);color:var(--ac);display:grid;place-items:center}.tw-avatar .tw-icon{width:38px;height:38px}
.tw-profile-info{min-width:0;flex:1}.tw-name-row{display:flex;align-items:center;gap:10px}.tw-name-row h1{min-width:0}.tw-name-row .tw-icon-button{color:var(--ac)}
#tw-name-display{display:flex;align-items:center;gap:10px;min-width:0}
.tw-sr-only{position:absolute;width:1px;height:1px;margin:-1px;padding:0;overflow:hidden;clip-path:inset(50%);white-space:nowrap;border:0}
#tw-rename{width:100%;min-width:0;gap:8px}
#tw-rename .tw-form-row{align-items:center}
#tw-name-input{font-size:32px;font-weight:800;line-height:1.2;padding:5px 9px;min-height:44px;flex:1 1 260px}
.tw-toolbar,.tw-form-row{display:flex;align-items:center;gap:10px;flex-wrap:wrap}
.tw-page button,.preview-toast button{cursor:pointer}
.tw-primary{font-size:15px;font-weight:600;padding:12px 18px;border-radius:12px;border:1px solid var(--ac);background:var(--ac);color:white;cursor:pointer}
.tw-collection-heading{display:flex;justify-content:space-between;gap:16px;align-items:center;flex-wrap:wrap}.tw-collection-heading h2{font-size:26px}
.tw-collection{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:20px}.tw-saved-card{background:var(--card);border:1px solid var(--bd);border-radius:20px;overflow:hidden}.tw-photo{height:150px;background:var(--card2);display:flex;align-items:flex-end;padding:16px;color:var(--mu);font-size:12px}.tw-saved-body{display:flex;flex-direction:column;gap:12px;padding:20px}.tw-saved-body h3{font-size:20px}.tw-empty{padding:45px 16px;display:flex;align-items:center;text-align:center;flex-direction:column;gap:16px}
.tw-auth{position:fixed;inset:0;margin:auto;border:0;border-radius:20px;padding:0;background:var(--card);color:var(--tx);width:calc(100% - 32px);max-width:460px;max-height:calc(100dvh - 40px);overflow:auto;box-shadow:0 20px 70px rgba(19,24,41,.2)}
.tw-auth[open]{display:block}.tw-auth::backdrop{background:rgba(19,24,41,.48)}
.tw-modal-open{overflow:hidden}
.tw-auth-box{position:relative;border:1px solid var(--bd);border-radius:20px;background:var(--card);padding:58px 32px 32px;max-width:460px;width:100%;display:flex;flex-direction:column;gap:20px}.tw-auth-box h2{font-size:28px;line-height:1.2}
.tw-auth-close{position:absolute;right:12px;top:10px}
.tw-page form{display:flex;flex-direction:column;gap:14px}.tw-page label{font-size:14px;font-weight:600}.tw-page input{font:inherit;font-size:16px;padding:13px 16px;border:1px solid var(--bd);border-radius:12px;background:var(--bg);color:var(--tx);min-width:0;width:100%}.tw-form-row input{flex:1 1 220px}.tw-page [role="alert"]{color:#c82a45;font-size:13px}.tw-page hr{border:0;border-top:1px solid var(--bd)}
.tw-logout-row{margin-top:16px;padding-top:24px;border-top:1px solid var(--bd)}
.tw-logout{font:inherit;font-weight:600;min-height:44px;padding:12px 28px;border:1px solid #d5294f;border-radius:12px;background:#d5294f;color:#fff;cursor:pointer}.tw-logout:hover{background:#b91f40;border-color:#b91f40}
.tw-toast{position:fixed;bottom:24px;left:16px;right:16px;z-index:60;max-width:580px;margin:0 auto;padding:16px 20px;border:1px solid var(--bd);border-radius:12px;background:var(--card);box-shadow:0 8px 35px rgba(19,24,41,.12);color:var(--tx);display:flex;justify-content:space-between;align-items:center;gap:12px;flex-wrap:wrap}
.tw-photo{position:relative;overflow:hidden}.tw-photo img{position:absolute;inset:0;width:100%;height:100%;object-fit:cover}
.tw-icon-button:disabled,.tw-primary:disabled,.tw-logout:disabled{opacity:.5;cursor:wait}
.tw-mobile-nav{display:none}
@media(max-width:900px){.tw-collection{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:720px){
  body{padding-bottom:calc(76px + env(safe-area-inset-bottom,0px))}
  .tw-collection{grid-template-columns:1fr}.tw-auth-box{padding:56px 22px 24px}.tw-auth-box h2{font-size:25px}.tw-profile-head h1{font-size:26px}
  .tw-toast{bottom:calc(84px + env(safe-area-inset-bottom,0px));margin:0 auto}.preview-actions{flex:none}.route-header-bar{align-items:flex-start}
  .bug-btn{bottom:calc(84px + env(safe-area-inset-bottom,0px))}
  .tw-mobile-nav{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));justify-items:center;position:fixed;bottom:0;left:0;right:0;z-index:55;justify-content:space-evenly;align-items:center;min-height:68px;padding:8px 0 calc(8px + env(safe-area-inset-bottom,0px));border-top:1px solid var(--bd);background:var(--card)}
  .tw-mobile-nav .tw-icon-button{width:52px;height:48px}.tw-mobile-nav .tw-icon{width:28px;height:28px}.tw-mobile-nav .active{color:var(--ac);background:var(--acs)}
  .tw-plan-heading h2{min-width:0}.tw-name-row{gap:4px}
  #tw-name-input{font-size:26px;flex-basis:100%}
}

#tw-phone-fields{display:flex;flex-direction:column;gap:8px}
.tw-code-cells{display:flex;gap:10px;justify-content:center;padding:8px 0}
.tw-page .tw-code-cell{width:calc((100% - 40px)/5);max-width:58px;height:64px;padding:0;text-align:center;font-size:26px;border-radius:14px;caret-color:var(--ac)}
.tw-code-cell:focus{outline:2px solid var(--ac);outline-offset:2px}
#tw-toast>span{flex:1 1 0;min-width:0}
#tw-toast [data-account-action="toast-action"]{margin-left:auto;flex-shrink:0}
#tw-toast{flex-wrap:nowrap}
.tw-saved-body>p{white-space:pre-line}

#tw-auth .tw-auth-box{padding-top:24px}
.tw-auth-header{display:flex;align-items:flex-start;gap:12px}
.tw-auth-header #tw-auth-title{order:1;flex:1;min-width:0;margin:0}
.tw-auth-header .tw-auth-close{order:2;position:static;width:34px;height:34px;padding:4px}
.tw-profile-head{align-items:flex-start}
.tw-saved-card{position:relative;cursor:pointer}
.tw-saved-card:focus-visible{outline:2px solid var(--ac);outline-offset:3px}
.tw-card-heart{position:absolute;right:12px;top:12px;background:transparent;color:var(--mu);z-index:1}
.tw-card-heart:hover{background:transparent}
.tw-card-heart[aria-pressed="true"]{color:#d5294f}
.tw-card-heart[aria-pressed="true"] .tw-icon{fill:currentColor}
#tw-save-changes .tw-auth-box{padding-left:24px;padding-right:24px}
#tw-save-title{width:100%;margin:0;padding:0;text-align:center;overflow-wrap:anywhere}
#tw-save-changes .tw-toolbar{flex-direction:column;align-items:center;justify-content:center}
#tw-save-changes .tw-toolbar>button{width:100%;min-width:0;max-width:100%;min-height:48px}
.tw-account-loading #page-home,.tw-account-loading #screen-route,.tw-account-loading footer{display:none!important}
.tw-account-loading body::after{content:'Загружаем личный кабинет…';display:block;text-align:center;padding:80px 24px;color:var(--mu)}
.tw-avatar{overflow:hidden}
.tw-avatar img{width:60px;height:60px;display:block;object-fit:cover}
.tw-nav-avatar{display:block;width:36px;height:36px;border-radius:50%;object-fit:cover;flex:none}
.tw-account-icon .tw-nav-avatar{width:32px;height:32px}
.tw-compass-logo{display:block;flex:none;object-fit:contain}
