/* UREDI PROFIL — potpuno izolovan UI */
#roomsMount:has(>.profile-editor-form),
#roomsMount.is-profile-editor{box-sizing:border-box;width:100%!important;max-width:none!important;height:100%;min-height:0;padding:0!important;overflow:auto!important;container-type:inline-size}
#roomsView.is-profile-editor{min-height:0;overflow:hidden!important}
#roomsMount .profile-editor-form{--pe-gap:14px;--pe-pad:16px;box-sizing:border-box;width:100%;max-width:none;min-height:100%;display:grid!important;grid-template-columns:minmax(0,1fr)!important;grid-auto-rows:max-content;align-content:start;gap:var(--pe-gap);margin:0;padding:var(--pe-pad);border:0;border-radius:0;color:#e8eef4;background:radial-gradient(700px 340px at 0 0,rgba(13,148,136,.14),transparent 64%),radial-gradient(540px 300px at 100% 0,rgba(109,40,217,.1),transparent 65%),#080d14;box-shadow:none}
#roomsMount .profile-editor-form *{box-sizing:border-box}.pe-message:empty{display:none}.pe-message:not(:empty){margin:0}
.pe-topbar{min-width:0;display:grid;grid-template-columns:36px 52px minmax(0,1fr) auto;align-items:center;gap:12px;padding:14px 16px;border:1px solid rgba(45,212,191,.18);border-radius:17px;background:linear-gradient(120deg,rgba(9,83,78,.65),rgba(14,22,34,.94) 46%,rgba(61,25,104,.35));box-shadow:inset 0 1px rgba(255,255,255,.055),0 14px 30px rgba(0,0,0,.2)}
.pe-back{width:36px;height:36px;display:grid;place-items:center;border:1px solid rgba(255,255,255,.09);border-radius:11px;color:#b6c4d0;background:rgba(5,10,17,.35);cursor:pointer}
#roomsMount .profile-editor-form .pe-avatar{position:relative;width:52px;height:52px;display:block;overflow:visible;border:2px solid rgba(94,234,212,.55);border-radius:16px;background:#0b111b;cursor:pointer;box-shadow:0 8px 20px rgba(8,145,178,.18)}
#roomsMount .profile-editor-form .pe-avatar img{width:100%;height:100%;display:block;object-fit:cover;border-radius:13px}#roomsMount .profile-editor-form .pe-avatar span{position:absolute;right:-4px;bottom:-4px;width:20px;height:20px;display:grid;place-items:center;border:2px solid #0d151f;border-radius:7px;color:#fff;background:#0d9488;font-size:.55rem}
#roomsMount .profile-editor-form .pf-file{position:absolute;width:1px;height:1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap}
.pe-title{min-width:0}.pe-title small{color:#77ebd9;font-size:.59rem;font-weight:950;letter-spacing:.11em}.pe-title h2{margin:3px 0 1px;color:#fff;font-size:1.08rem}.pe-title p{margin:0;color:#8fa0b3;font-size:.7rem}.pe-status{display:flex;align-items:center;gap:7px;padding:8px 10px;border:1px solid rgba(94,234,212,.16);border-radius:10px;color:#a7f3e8;background:rgba(13,148,136,.07);font-size:.64rem;font-weight:850}
.pe-tabs{width:100%;min-width:0;display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:7px;padding:6px;border:1px solid rgba(148,163,184,.15);border-radius:15px;background:rgba(7,13,21,.88);box-shadow:inset 0 1px rgba(255,255,255,.035)}
.pe-tabs button{min-width:0;height:62px;display:grid;grid-template-columns:34px minmax(0,1fr);align-items:center;gap:9px;padding:7px 13px;border:1px solid transparent;border-radius:11px;color:#8393a6;background:transparent;font-family:inherit;cursor:pointer}.pe-tabs button>i{width:34px;height:34px;display:grid;place-items:center;border-radius:10px;color:#8495a9;background:rgba(148,163,184,.075)}.pe-tabs button>span{min-width:0;display:grid;gap:2px;text-align:left}.pe-tabs b{font-size:.76rem}.pe-tabs small{overflow:hidden;color:#66788d;font-size:.61rem;text-overflow:ellipsis;white-space:nowrap}.pe-tabs button.is-active{border-color:rgba(45,212,191,.22);color:#f2fffd;background:linear-gradient(135deg,rgba(13,148,136,.22),rgba(2,132,199,.08));box-shadow:0 8px 18px rgba(0,0,0,.14)}.pe-tabs button.is-active>i{color:#fff;background:linear-gradient(145deg,#0d9488,#0284c7)}.pe-tabs button.is-active small{color:#88cfc5}
.pe-pane{min-width:0;display:none}.pe-pane.is-active{display:grid;gap:var(--pe-gap)}.pe-basic-pane.is-active{grid-template-columns:repeat(2,minmax(0,1fr));align-items:stretch}
#roomsMount .profile-editor-form .pe-section{position:relative;min-width:0;display:grid;align-content:start;gap:14px;margin:0;padding:var(--pe-pad);overflow:hidden;border:1px solid rgba(148,163,184,.15);border-radius:17px;background:linear-gradient(155deg,rgba(24,34,47,.96),rgba(9,15,24,.98));box-shadow:inset 0 1px rgba(255,255,255,.045),0 13px 28px rgba(0,0,0,.17)}
#roomsMount .profile-editor-form .pe-section:before{content:"";position:absolute;left:18px;right:18px;top:-1px;height:2px;background:linear-gradient(90deg,transparent,#2dd4bf,transparent);opacity:.7}#roomsMount .profile-editor-form .pe-section>h3{display:flex;align-items:center;gap:10px;margin:0;padding-bottom:12px;border-bottom:1px solid rgba(148,163,184,.1);color:#edf4f7;font-size:.84rem}#roomsMount .profile-editor-form .pe-section>h3 i{width:37px;height:37px;display:grid;place-items:center;border-radius:11px;color:#94eee0;background:rgba(13,148,136,.14)}
#roomsMount .profile-editor-form .pf-clean-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:13px}#roomsMount .profile-editor-form .pf-control{min-width:0;display:grid;gap:7px;margin:0}#roomsMount .profile-editor-form .pf-control>span{color:#dbe5ec;font-size:.72rem;font-weight:800}
#roomsMount .profile-editor-form .cr-select,#roomsMount .profile-editor-form .pf-input,#roomsMount .profile-editor-form .pf-textarea{width:100%;max-width:100%;outline:0;border:1px solid rgba(148,163,184,.2);border-radius:11px;color:#edf3f7;background:#070c13;box-shadow:inset 0 1px 4px rgba(0,0,0,.22);font-family:inherit;font-size:.78rem;transition:.15s ease}#roomsMount .profile-editor-form .cr-select,#roomsMount .profile-editor-form .pf-input{height:45px;padding:0 12px}#roomsMount .profile-editor-form .pf-textarea{min-height:120px;padding:11px 12px;line-height:1.45;resize:vertical}#roomsMount .profile-editor-form .cr-select:focus,#roomsMount .profile-editor-form .pf-input:focus,#roomsMount .profile-editor-form .pf-textarea:focus{transform:none;border-color:rgba(45,212,191,.48);background:#09111a;box-shadow:0 0 0 3px rgba(13,148,136,.09)}
#roomsMount .profile-editor-form .cr-inline{position:relative;display:flex;align-items:center}#roomsMount .profile-editor-form .cr-inline .cr-select{padding-right:43px}#roomsMount .profile-editor-form .cr-suffix{position:absolute;right:12px;color:#6f8297;font-size:.66rem;pointer-events:none}
#roomsMount .profile-editor-form .pf-control-wide{grid-column:1/-1}.pf-choice-block{display:grid;gap:9px;padding:11px;border:1px solid rgba(148,163,184,.11);border-radius:12px;background:rgba(4,9,15,.4)}.pf-choice-title{color:#d7e2e9;font-size:.72rem;font-weight:850}.pf-choice-grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(105px,1fr));gap:7px}.pf-choice{position:relative;cursor:pointer}.pf-choice>input{position:absolute;opacity:0;pointer-events:none}.pf-choice>span{min-height:36px;display:flex;align-items:center;justify-content:center;padding:6px 9px;border:1px solid rgba(148,163,184,.13);border-radius:9px;color:#93a3b5;background:rgba(255,255,255,.025);font-size:.67rem;font-weight:750;text-align:center}.pf-choice>input:checked+span{border-color:rgba(45,212,191,.34);color:#dffffa;background:rgba(13,148,136,.14);box-shadow:inset 0 0 0 1px rgba(45,212,191,.05)}
.pe-actions{position:relative;z-index:4;display:flex;justify-content:flex-end;gap:9px;padding:12px;border:1px solid rgba(148,163,184,.15);border-radius:14px;background:rgba(11,18,28,.92)}.pe-cancel,.pe-save{min-width:150px;height:46px;display:inline-flex;align-items:center;justify-content:center;gap:8px;border-radius:11px;font-family:inherit;font-size:.73rem;font-weight:900;cursor:pointer}.pe-cancel{border:1px solid rgba(148,163,184,.16);color:#c4d0da;background:#17212d}.pe-save{border:1px solid rgba(94,234,212,.22);color:#fff;background:linear-gradient(135deg,#0d9488,#0284c7);box-shadow:0 9px 19px rgba(2,132,199,.2)}
@container(max-width:760px){.pe-basic-pane.is-active{grid-template-columns:1fr}#roomsMount .profile-editor-form .pf-clean-grid{grid-template-columns:1fr}}
@media(max-width:640px){#roomsMount .profile-editor-form{--pe-gap:10px;--pe-pad:12px;padding:0 10px 10px}.pe-topbar{grid-template-columns:34px 44px minmax(0,1fr);gap:8px;margin:0 -10px;padding:10px;border-width:0 0 1px;border-radius:0}.pe-back{width:34px;height:34px}#roomsMount .profile-editor-form .pe-avatar{width:44px;height:44px;border-radius:13px}#roomsMount .profile-editor-form .pe-avatar img{border-radius:10px}.pe-title h2{font-size:.88rem}.pe-title p{font-size:.61rem}.pe-status{display:none}.pe-tabs{position:sticky;top:0;z-index:8;width:calc(100% + 20px);margin:0 -10px;padding:6px 7px;border-width:0 0 1px;border-radius:0;background:rgba(8,13,20,.96);backdrop-filter:blur(12px)}.pe-tabs button{height:54px;grid-template-columns:1fr;justify-items:center;gap:3px;padding:4px}.pe-tabs button>i{width:25px;height:25px;border-radius:8px;font-size:.68rem}.pe-tabs button>span{display:block;text-align:center}.pe-tabs b{font-size:.64rem}.pe-tabs small{display:none}.pe-pane.is-active,.pe-basic-pane.is-active{grid-template-columns:1fr;gap:10px}#roomsMount .profile-editor-form .pe-section{padding:12px;border-radius:14px}#roomsMount .profile-editor-form .pf-clean-grid{grid-template-columns:1fr;gap:11px}.pf-choice-grid{grid-template-columns:repeat(2,minmax(0,1fr))}.pe-actions{position:sticky;bottom:0;z-index:7;margin:0 -10px -10px;padding:8px 10px calc(8px + env(safe-area-inset-bottom));border-width:1px 0 0;border-radius:0;background:rgba(8,13,20,.96);backdrop-filter:blur(12px)}.pe-actions>*{flex:1;min-width:0}.pe-cancel,.pe-save{height:45px;font-size:.67rem}}

/* Unified profile editor: quiet surfaces, consistent controls and visible feedback. */
#roomsMount.is-profile-editor,#roomsMount:has(>.profile-editor-form){scrollbar-width:thin;scrollbar-color:rgba(96,165,250,.72) transparent;scrollbar-gutter:auto}
#roomsMount.is-profile-editor::-webkit-scrollbar,#roomsMount:has(>.profile-editor-form)::-webkit-scrollbar{width:8px}
#roomsMount.is-profile-editor::-webkit-scrollbar-track,#roomsMount:has(>.profile-editor-form)::-webkit-scrollbar-track{background:transparent}
#roomsMount.is-profile-editor::-webkit-scrollbar-thumb,#roomsMount:has(>.profile-editor-form)::-webkit-scrollbar-thumb{min-height:38px;background:linear-gradient(180deg,rgba(96,165,250,.82),rgba(59,130,246,.62));border-radius:999px}
.profile-save-notice{position:fixed;top:calc(18px + env(safe-area-inset-top));left:50%;transform:translateX(-50%);z-index:2147483000;display:flex;align-items:center;gap:12px;width:max-content;max-width:calc(100vw - 28px);box-sizing:border-box;padding:14px 14px 14px 18px;border:1px solid #7dd8ac80;border-radius:16px;background:#18382e;color:#eafff3;box-shadow:0 12px 40px #0006;font:600 14px/1.45 system-ui,sans-serif;animation:profile-notice-in .18s ease-out}
.profile-save-notice>i{font-size:20px;color:#a1e9ca}.profile-save-notice>span{min-width:0;overflow-wrap:anywhere}.profile-save-notice>button{flex:none;width:32px;height:32px;padding:0;border:0;border-radius:9px;background:#ffffff0c;color:inherit;font:22px/1 system-ui;cursor:pointer}.profile-save-notice.is-error{background:#44252b;border-color:#e7a1a166}.profile-save-notice.is-error>i{color:#ffb7b7}.profile-save-notice>button:focus-visible{outline:2px solid currentColor;outline-offset:2px}
@keyframes profile-notice-in{from{opacity:0;translate:0 -8px}to{opacity:1;translate:0 0}}
.profile-save-notice{max-width:calc(100vw - 28px)}
@media(max-width:640px){.profile-save-notice{top:calc(12px + env(safe-area-inset-top));font-size:13px}}
@media(prefers-reduced-motion:reduce){.profile-save-notice{animation:none}}

/* Space-efficient layout; retain the original tab and field styling. */
#roomsMount .profile-editor-form{--pe-gap:9px;--pe-pad:12px}
#roomsMount .profile-editor-form .pe-topbar{padding:10px 12px;gap:9px}
#roomsMount .profile-editor-form .pe-tabs{padding:4px;gap:4px}
#roomsMount .profile-editor-form .pe-tabs button{height:54px;padding:6px 9px;gap:7px}
#roomsMount .profile-editor-form .pe-section{gap:10px;padding:12px}
#roomsMount .profile-editor-form .pe-section>h3{padding-bottom:8px;gap:8px}
#roomsMount .profile-editor-form .pf-clean-grid{gap:10px}
#roomsMount .profile-editor-form .pf-control{gap:5px}
#roomsMount .profile-editor-form .pf-choice-block{padding:8px;gap:7px}
#roomsMount .profile-editor-form .pe-actions{padding:8px;gap:8px}
#roomsMount.is-profile-editor::-webkit-scrollbar-thumb:hover,#roomsMount:has(>.profile-editor-form)::-webkit-scrollbar-thumb:hover{background:linear-gradient(180deg,#7dd3fc,#3b82f6)}
@media(max-width:640px){#roomsMount .profile-editor-form{--pe-gap:8px;--pe-pad:10px;padding:0 8px 8px}#roomsMount .profile-editor-form .pe-topbar{margin:0 -8px;padding:8px}#roomsMount .profile-editor-form .pe-tabs{width:calc(100% + 16px);margin:0 -8px;padding:4px 6px}#roomsMount .profile-editor-form .pe-tabs button{height:50px;padding:4px;gap:3px}#roomsMount .profile-editor-form .pe-section{padding:10px;gap:9px}#roomsMount .profile-editor-form .pe-pane.is-active{gap:8px}#roomsMount .profile-editor-form .pe-actions{margin:0 -8px -8px;padding:6px 8px calc(6px + env(safe-area-inset-bottom))}}

/* Interest picker uses the native modal layer and stays inside the profile form. */
#profileEditForm .interest-app-dialog:not([open]){display:none!important}
#profileEditForm .interest-app-dialog[open]{display:block;position:fixed;inset:0;margin:0;padding:0;width:100vw;height:100dvh;max-width:none;max-height:none;border:0;border-radius:0;background:#0b131e;color:#edf3f7;overflow:hidden;box-sizing:border-box}
.interest-app-dialog::backdrop{background:#0b131e}
#profileEditForm .interest-app-dialog>section{display:flex;flex-direction:column;width:100%;height:100%;max-height:none;max-width:800px;margin:auto;border:0;border-radius:0;background:#0b131e;box-shadow:none;overflow:hidden}
#profileEditForm .interest-app-dialog>section>header{flex:none;padding:calc(12px + env(safe-area-inset-top)) 14px 12px;gap:12px;border-bottom:1px solid #ffffff0c}
#profileEditForm .interest-app-dialog>section>header button{width:44px;height:44px;border-radius:12px;color:#a1e9ca}
#profileEditForm .interest-app-dialog [data-interest-count]{background:#a1e9ca12!important;color:#a1e9ca!important;border-radius:10px}
#profileEditForm .interest-app-dialog .pf-interest-search{flex:none;margin:12px 14px 10px;border:1px solid #ffffff12;border-radius:13px;background:#101e2a;padding:0 12px;min-height:46px}
#profileEditForm .interest-app-dialog .pf-interest-search input{font-size:16px;color:#edf3f7;background:transparent}
#profileEditForm .interest-app-dialog .pf-interest-categories{display:flex;flex-wrap:wrap;flex:none;gap:5px;padding:0 14px 10px;overflow:visible}
#profileEditForm .interest-app-dialog .pf-interest-categories button{min-height:34px;padding:7px 11px;border-radius:999px;background:#ffffff04;border:1px solid #ffffff12;color:#a8bbc7;font-size:11px}
#profileEditForm .interest-app-dialog .pf-interest-categories button.is-active{background:#25443c;color:#c9f4df;border-color:#a1e9ca40}
#profileEditForm .interest-app-dialog .pf-interest-grid{flex:1;display:grid;grid-template-columns:repeat(3,minmax(0,1fr))!important;gap:7px!important;padding:4px 14px 14px;min-height:0;overflow:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:#60a5fa80 transparent}
#profileEditForm .interest-app-dialog .pf-interest-choice{min-width:0}
#profileEditForm .interest-app-dialog .pf-interest-choice span{min-height:48px!important;gap:8px;padding:8px 10px!important;border:1px solid #ffffff0c;border-radius:13px!important;background:#15222f;color:#c7d7df;font-size:12px!important;white-space:nowrap;overflow:hidden;text-overflow:ellipsis}
#profileEditForm .interest-app-dialog .pf-interest-choice input:checked+span{background:#1c3c32;border-color:#a1e9ca80;color:#dcffec}
#profileEditForm .interest-app-dialog .pf-interest-choice input:checked+span:after{content:'✓';margin-left:auto;color:#a1e9ca}
#profileEditForm .interest-app-dialog .pf-interest-choice input:disabled+span{opacity:.4}
#profileEditForm .interest-app-dialog .pf-interest-choice input:focus-visible+span{outline:2px solid #a1e9ca;outline-offset:2px}
#profileEditForm .interest-app-dialog .pf-interest-choice span i{box-shadow:none;background:#a1e9ca14;color:#a1e9ca}
#profileEditForm .interest-app-dialog .interest-app-status{flex:none;margin:0;padding:0 14px 8px;color:#a1e9ca;font-size:12px}
#profileEditForm .interest-app-dialog .interest-app-status:empty{display:none}
#profileEditForm .interest-app-dialog>section>footer{flex:none;background:#101c28;padding:10px 14px calc(10px + env(safe-area-inset-bottom))}
#profileEditForm .interest-app-dialog>section>footer button{border-radius:13px;background:#a1e9ca;color:#173c2d;box-shadow:none;font-weight:700}
#profileEditForm .pf-interest-editor{background:#101c2855;border:1px solid #ffffff0e;border-radius:15px;padding:12px}
#profileEditForm .pf-interest-open{min-height:44px;border-radius:12px;background:#a1e9ca0c;border:1px solid #a1e9ca30;color:#c6f2df;box-shadow:none}
#profileEditForm .pf-interest-selected button{border-radius:999px;background:#1a2c35;border:1px solid #a1e9ca22;color:#d5e9e2;min-height:36px}
@media(max-width:600px){#profileEditForm .interest-app-dialog .pf-interest-grid{grid-template-columns:repeat(2,minmax(0,1fr))!important}}
@media(max-width:360px){#profileEditForm .interest-app-dialog .pf-interest-grid{grid-template-columns:1fr!important}}
