.profile-menu-sheet__avatar--editable {
    cursor: pointer;
    transition: transform 0.15s ease, opacity 0.15s ease;
    position: relative;
}

.profile-menu-sheet__avatar--editable:active {
    transform: scale(0.94);
}

#profileBlock{
	margin-top:24px;
	position:relative;
	width:100%;
}
.profile-menu-sheet__avatar--editable:focus-visible {
    outline: 2px solid var(--select);
    outline-offset: 2px;
}

.user_header_section{
	display:flex;
	padding:12px;
	justify-content: space-between;
	align-items: center;
}

.user_header_section h2{
padding:0;
}

.profile-menu-sheet__toggle-label {
    display: flex;
    align-items: center;
    justify-content: space-between;
    user-select: none;
}

.profile-menu-toggle-switch {
    width: 48px!important;
    height: 20px!important;
    background: var(--top)!important;
    border-radius: 12px!important;
    position: relative!important;
    outline: none!important;
    cursor: pointer!important;
    transition: background 0.3s ease!important;
    flex-shrink: 0!important;
    margin: 0!important;
    border: 1px solid var(--overlaytop)!important;
}

.profile-menu-toggle-switch::after {
    content: '';
    position: absolute;
    top: 2px;
    left: 2px;
    width:20px;
    height: 14px;
    background: var(--subselect);
    border-radius: 12px;
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    opacity: 0.8;
}

.profile-menu-toggle-switch:checked {
    background: var(--select);
}

.profile-menu-toggle-switch:checked::after {
    transform: translateX(20px);
    background: var(--select);
    opacity: 1;
}


.profile-menu-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 48px;
    height: 48px;
    padding: 0;
    border: none;
    border-radius: 50%;
    background: none;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.15s ease;
    flex-shrink: 0;
}

.profile-menu-btn:hover  { background: var(--overlaytop); }
.profile-menu-btn:active { transform: scale(0.94); }

.profile-menu-btn img {
    width: 20px;
    height: 20px;
    filter: var(--filter);
}

.profile-tab-panel {
    width: 100%;
    display: flex;
    flex-direction: column;
}

.profile-tab-panel .profile-tab-slide {
    width: 100%;
}

.profile-menu-sheet {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}


.profile-avatar-btn {
	width:24px;
	height:24px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 2px;
    background: var(--overlaytop);
    border: none;
    cursor: pointer;
    border-radius: 50%;
}

.profile-avatar-btn .profile-avatar {
	width:100%;
	height:100%;
        border: none;
        border-radius: 50%;
        cursor: pointer;
        display: flex;
        align-items: center;
        justify-content: center;
        background: var(--overlayPanel);
        backdrop-filter: blur(8px);
        box-shadow: 0 0 12px hwb(0deg 0% 100% / 12%), inset 0 0 12px hwb(0deg 100% 0% / 2%);
}

.profile-avatar-btn .profile-avatar img {
    width: 24px;
    height: 24px;
    object-fit: cover;
}

.cardHeader-logo {
    display: flex;
    align-items: center;
    justify-content: center;
}

.cardHeader-logo img {
    width: 80px;
    filter: var(--filter);
}


.profile-menu-sheet.visible {
    opacity: 1;
    pointer-events: auto;
}

.profile-menu-sheet__content {
    width: 100%;
    max-width: 800px;
    max-height: 80vh;
    background: var(--overlay);
    border-radius: 24px 24px 0 0;
    padding: 12px 12px calc(12px + var(--safe-bottom));
    display: flex;
    flex-direction: column;
    gap: 4px;
    overflow-y: auto;
    overscroll-behavior: contain;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    border-top: 1px solid var(--overlaytop);
	backdrop-filter:blur(8px);
}

.profile-menu-sheet.visible .profile-menu-sheet__content {
    transform: translateY(0);
}

.profile-menu-sheet__handle {
    width: 32px;
    height: 4px;
    background: var(--overlaytop);
    border-radius: 4px;
    margin: 4px auto 4px;
    flex-shrink: 0;
}

.profile-menu-sheet__header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    border-bottom: 1px solid var(--overlaytop);
    margin-bottom: 8px;
    flex-shrink: 0;
    flex-direction: column;
}

.profile-menu-sheet__avatar {
    width: 180px;
    height: 180px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
    background: var(--mid);
    display: flex;
    align-items: center;
    justify-content: center;
}

.profile-menu-sheet__avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-menu-sheet__avatar .avatar-initial-fallback {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--mid);
    color: var(--text);
    font-size: 24px;
    font-weight: 600;
    border-radius: 50%;
}

.profile-menu-sheet__meta {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: center;
	padding:12px;
}

.profile-menu-sheet__name {
    font-size: 16px;
    font-weight: 600;
    color: var(--text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.profile-menu-sheet__status {
    font-size: 12px;
    color: var(--text);
	opacity:0.4;
}

.profile-menu-sheet__item {
    display: flex;
    align-items: center;
    gap: 12px;
    width: 100%;
    padding: 14px;
    background: none;
    border: none;
    border-radius: 16px;
    color: var(--text);
    font-size: 14px;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s ease, transform 0.08s ease;
    -webkit-tap-highlight-color: transparent;
}

.profile-menu-sheet__item:hover  { background: var(--overlaytop); }
.profile-menu-sheet__item:active { transform: scale(0.98); }

.profile-menu-sheet__item img {
    width: 16px;
    height: 16px;
    filter: var(--filter);
    flex-shrink: 0;
    pointer-events: none;
}

.profile-menu-sheet__item span {
    flex: 1;
    pointer-events: none;
}

.profile-menu-sheet__item.danger {
    color: #ff6d6d;
}

.profile-menu-sheet__item.danger img {
    filter: invert(48%) sepia(79%) saturate(300%) hue-rotate(330deg) brightness(100%) contrast(101%);
}

.profile-menu-sheet__divider {
    height: 1px;
    background: var(--overlaytop);
    margin: 6px 12px;
    flex-shrink: 0;
}

.profile-tabs-sheet {
    position: fixed;
    inset: 0;
    z-index: 99998;
    background: rgb(0 0 0 / 50%);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.25s ease;
}

.profile-tabs-sheet.visible {
    opacity: 1;
    pointer-events: auto;
}

.profile-tabs-sheet__content {
    width: 100%;
    max-width: 800px;
    background: var(--overlay);
    border-radius: 24px 24px 0 0;
    padding: 12px 12px calc(12px + var(--safe-bottom));
    display: flex;
    flex-direction: column;
    gap: 4px;
    transform: translateY(100%);
    transition: transform 0.3s cubic-bezier(0.22, 1, 0.36, 1);
    border-top: 1px solid var(--overlaytop);
}

.profile-tabs-sheet.visible .profile-tabs-sheet__content {
    transform: translateY(0);
}

.profile-tabs-sheet__handle {
    width: 32px;
    height: 4px;
    background: var(--overlaytop);
    border-radius: 4px;
    margin: 4px auto 12px;
    flex-shrink: 0;
}

.profile-tabs-sheet__title {
    padding:8px;
    font-size: 14px;
    font-weight: 600;
color:var(--text);
    margin-bottom: 8px;
}

.profile-tabs-sheet__item {
    display: flex;
    align-items: center;
    gap: 8px;
    width: 100%;
    padding: 12px;
    background: none;
    border: none;
    border-radius: 16px;
    color: var(--text);
    font-size: 12px;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s ease;
}

.profile-tabs-sheet__item:hover  { background: var(--overlaytop); }

.profile-tabs-sheet__item.active {
    background: var(--overlaytop);
    color: var(--text);
    font-weight: 500;
}

.profile-tabs-sheet__item img {
    width: 16px;
    height: 16px;
    filter: var(--filter);
    flex-shrink: 0;
    pointer-events: none;
}

.profile-tabs-sheet__item span {
    flex: 1;
    pointer-events: none;
}

.profile-menu-sheet__name--editable {
    cursor: text;
    border-radius: 8px;
    transition: background 0.15s ease, box-shadow 0.15s ease;
    outline: none;
    -webkit-user-select: text;
    user-select: text;
    -webkit-touch-callout: default;
	width:100%;
	text-align:center;
}

.profile-menu-sheet__name--editable:hover {
    background: var(--overlaytop);
}

.profile-menu-sheet__name--editable:focus {
    background: var(--mid);
    box-shadow: 0 0 0 2px var(--select);
}

.profile-menu-sheet__name--editable:empty::before {
    content: attr(data-placeholder);
    color: var(--subtext);
    opacity: 0.5;
    pointer-events: none;
}
#profileLikedContent {
	display: flex;
	gap: 16px;
	flex-direction: column;
}


.profileContent {
	/* padding-top:60px; */
	height: 100%;
	display: flex;
	flex-direction: column;
}

@media screen and (min-width:800px){
	.profileContent {
	padding-top:0px;
	}
}

.profile-tab-slider {
	display: flex;
	flex-direction: row;
	width: 100%;
	overflow-x: auto;
	overflow-y: hidden;
	scroll-snap-type: x mandatory;
	scroll-behavior: smooth;
	scrollbar-width: none;
	-ms-overflow-style: none;
	overscroll-behavior-x: contain;
	touch-action: pan-x pan-y;
	-webkit-overflow-scrolling: touch;
}

.profile-tab-slider::-webkit-scrollbar {
	display: none;
}

.profile-tab-slide {
	gap:12px;
	padding:12px;
	flex: 1;
	min-width: 100%;
	scroll-snap-align: start;
	scroll-snap-stop: always;
	display: flex;
	flex-direction: column;
	box-sizing: border-box;
}

.profile-tab-slide-inner {
	width: 100%;
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.profile-liked-section {
		width: 100%;
		display: flex;
		flex-direction: column;
}

.profile-tab-slider.no-smooth {
	scroll-behavior: auto;
}

.profile-auth-btn .auth-btn-label {
	white-space: nowrap;
}
	
.history-recent-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
	width: 100%;
}


.savedHeader{
	display:flex;
	gap:12px;
	flex-direction: column;
}

.profile-inner-search {
	display:none;
    height: 40px;
    z-index: auto;
}

.profile-inner-search-hidden {
    display: none !important;
}



#authModal {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: var(--overlay);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
}

#authModal .edit-modal-content {
    width: 100%;
    max-width: 400px;
    background: var(--main);
    border-radius: 24px;
    border: 1px solid var(--overlaytop);
    box-shadow: 0 20px 64px rgba(0, 0, 0, 0.4);
    display: flex;
    flex-direction: column;
    overflow: hidden;
}

#authModal .edit-modal-header {
    padding: 16px;
    border-bottom: 1px solid var(--overlaytop);
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: var(--low);
}

#authModal .edit-modal-header h2 {
    font-size: 16px;
    color: var(--text);
    margin: 0;
}

#authModal .edit-modal-close {
    background: none;
    border: none;
    cursor: pointer;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0.4;
    transition: opacity 0.2s ease;
    padding: 0;
}

#authModal .edit-modal-close:hover {
    opacity: 1;
}

#authModal .edit-modal-close img {
    width: 16px;
    height: 16px;
    filter: var(--filter);
}

#authModal .edit-modal-body {
    padding: 24px 16px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

#authModal .edit-field {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

#authModal .edit-field label {
    font-size: 12px;
    color: var(--subtext);
    font-weight: 400;
}

#authModal .edit-field input {
    width: 100%;
    padding: 12px;
    background: var(--mid);
    border: 1px solid transparent;
    border-radius: var(--itemborder);
    color: var(--text);
    font-size: 14px;
    outline: none;
    transition: border-color 0.2s ease;
}

#authModal .edit-field input:focus {
    border-color: var(--select);
}

#authModal .edit-field input::placeholder {
    color: var(--subtext);
    opacity: 0.5;
}
#authModal #authCodeInput {
    font-size: 24px;
    text-align: center;
    letter-spacing: 12px;
    padding: 16px 12px;
}

#authModal .edit-btn {
    padding: 12px;
    border-radius: 24px;
    border: none;
    cursor: pointer;
    font-weight: 600;
    font-size: 14px;
    transition: all 0.2s ease;
    width: 100%;
}

	#authTelegramLoginBtn{
		background:none;
		display:flex;
		gap:6px;
		flex-direction: row;
		align-items: center;
		justify-content: center;
	}

		#authTelegramLoginBtn span{
		font-size:12px;
		}

#authModal .edit-btn-save {
    background: var(--select);
    color: var(--main);
}

#authModal .edit-btn-save:hover {
    opacity: 0.8;
}

#authModal .edit-btn-save:disabled {
    opacity: 0.4;
    cursor: not-allowed;
}

#authModal #authCodeBlock {
    border-top: 1px solid var(--overlaytop);
    padding-top: 24px;
    margin-top: 8px;
}

#authModal #authStatus {
    text-align: center;
    font-size: 12px;
    min-height: 16px;
    margin: 0;
    transition: color 0.2s ease;
}

.profile-name-edit {
    outline: none;
    border-radius: 8px;
    transition: background 0.2s ease, box-shadow 0.2s ease;
    cursor: default;
    word-break: break-word;
}

.profile-name-edit[contenteditable="true"] {
    cursor: text;
}

.profile-name-edit[contenteditable="true"]:hover {
    background: var(--overlaytop);
}

.profile-name-edit[contenteditable="true"]:focus {
    background: var(--mid);
    box-shadow: 0 0 0 2px var(--select);
}

.profile-name-edit:empty::before {
    content: attr(data-placeholder);
    color: var(--subtext);
    opacity: 0.4;
    pointer-events: none;
}

.profile-tabs-dropdown {
    position: fixed;
    top: 60px;
    right: 12px;
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transform: translateY(-12px) scale(0.95);
    transform-origin: top right;
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.profile-tabs-dropdown.visible {
    opacity: 1;
    pointer-events: auto;
    transform: translateY(0) scale(1);
}

.profile-tabs-dropdown__content {
    background: var(--overlayPanel);
    border: 1px solid var(--overlaytop);
    border-radius:24px;
    box-shadow: 0 10px 48x rgba(0, 0, 0, 0.2), 0 0 0 1px var(--overlaytop);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    padding: 6px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.profile-tabs-dropdown__item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 12px;
    border-radius: 12px;
    border: none;
    background: none;
    color: var(--text);
    font-size: 14px;
    text-align: left;
    cursor: pointer;
    transition: background 0.15s ease, color 0.15s ease;
}

.profile-tabs-dropdown__item.active {
    background: var(--overlaytop);
    color: var(--text);
    font-weight: 500;
}

.profile-tabs-dropdown__item img {
    width: 14px;
    height: 14px;
    filter: var(--filter);
    flex-shrink: 0;
    pointer-events: none;
}