/* Refined search surface, scoped away from the profile and settings forms. */
.dialog.fullScr:has(.filter-page--refined){max-width:480px}
.dialog .filter-page--refined{padding-bottom:20px}
.dialog .filter-page--refined .filter-header{border-bottom:0;gap:6px;background:var(--rateu-bg,#f7f3ec);min-height:66px;margin-bottom:8px}
.dialog .filter-page--refined .filter-header h1{text-transform:none;font-size:28px}
.dialog .filter-page--refined .filter-reset{border:0;background:none;color:var(--rateu-muted,#77716a);font:400 12px 'Rubik',sans-serif;min-height:40px;padding:4px;text-decoration:underline;text-underline-offset:3px;cursor:pointer}
.dialog .filter-page--refined .filter-form{max-width:none}
.dialog .filter-page--refined .filter-range-card,.dialog .filter-page--refined .filter-choice-card{padding:18px 16px;border:1px solid #e9e5df;border-radius:18px;background:#fff}
.dialog .filter-page--refined .filter-range-heading{display:flex;align-items:center;justify-content:space-between;gap:12px;font-size:14px;font-weight:500;color:var(--rateu-ink,#191919)}
.dialog .filter-page--refined .filter-range-heading label{margin:0;padding:0;font:inherit;color:inherit}
.dialog .filter-page--refined output{font-size:12px;font-weight:400;color:var(--rateu-muted,#77716a);text-align:right}
.dialog .filter-page--refined #distance-value{font-weight:400;font-size:12px;color:var(--rateu-muted,#77716a)}
.dialog .filter-page--refined .filter-age-slider{padding:19px 0;margin-top:8px}
.dialog .filter-page--refined #age-slider{height:6px;margin:0 9px;border:0;border-radius:6px;background:#e5dfd7}
.dialog .filter-page--refined #age-slider .ui-slider-range{height:6px;border:0;border-radius:6px;background:var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined #age-slider .ui-slider-handle{top:50%;width:44px;height:44px;margin-left:-22px;padding:0;border:0;border-radius:50%;background:transparent;box-shadow:none;transform:translateY(-50%);touch-action:none}
.dialog .filter-page--refined #age-slider .ui-slider-handle::after{content:'';position:absolute;top:13px;left:13px;width:18px;height:18px;border-radius:50%;background:var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined #age-slider .ui-slider-handle:focus-visible{outline:0}
.dialog .filter-page--refined #age-slider .ui-slider-handle:focus-visible::after{outline:2px solid var(--rateu-ink,#191919);outline-offset:3px}
.dialog .filter-page--refined .filter-distance-section{border-top:1px solid var(--rateu-line,#ded9d1);margin-top:20px;padding-top:18px}
.dialog .filter-page--refined #distance-slider{display:block;appearance:none;-webkit-appearance:none;width:100%;height:36px;margin:8px 0 2px;border:0;padding:0;background:transparent;cursor:pointer}
.dialog .filter-page--refined #distance-slider::-webkit-slider-runnable-track{height:6px;border:0;border-radius:6px;background:linear-gradient(to right,var(--rateu-accent,#d31d29) var(--distance-progress,0%),#e5dfd7 var(--distance-progress,0%))}
.dialog .filter-page--refined #distance-slider::-webkit-slider-thumb{appearance:none;-webkit-appearance:none;width:18px;height:18px;margin-top:-6px;border:0;border-radius:50%;background:var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined #distance-slider::-moz-range-track{height:6px;border:0;border-radius:6px;background:#e5dfd7}
.dialog .filter-page--refined #distance-slider::-moz-range-progress{height:6px;background:var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined #distance-slider::-moz-range-thumb{width:18px;height:18px;border:0;border-radius:50%;background:var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined .filter-distance-help{display:flex;align-items:center;justify-content:space-between;gap:8px;flex-wrap:wrap;color:var(--rateu-muted,#77716a);font-size:11px;line-height:1.5}
.dialog .filter-page--refined #toggle-unit{margin:0;padding:6px 0;min-height:32px;white-space:nowrap;border:0;background:none;font:inherit;color:inherit;text-decoration:underline;text-underline-offset:2px;cursor:pointer}
.dialog .filter-page--refined .filter-section-label{font:500 12px 'Rubik',sans-serif;color:var(--rateu-muted,#77716a);margin:22px 0 11px;text-transform:none}
.dialog .filter-page--refined .filter-choice-card{padding:0 16px}
.dialog .filter-page--refined .filter-choice{position:relative;display:block;margin:0;padding:16px 0;border-bottom:1px solid var(--rateu-line,#ded9d1);color:var(--rateu-ink,#191919)}
.dialog .filter-page--refined .filter-choice:last-child{border-bottom:0}
.dialog .filter-page--refined .filter-choice-label{display:block;margin:0 26px 4px 0;font-size:14px;font-weight:400;line-height:1.4}
.dialog .filter-page--refined .field-summary{display:flex;flex-direction:column;gap:0;align-items:stretch;width:100%;min-height:26px;margin:-16px 0;padding:16px 0;border:0;border-radius:0;background:transparent;text-align:left;font:400 12px/1.5 'Rubik',sans-serif;cursor:pointer;box-shadow:none}
.dialog .filter-page--refined .field-values{display:flex;align-items:center;min-height:26px;color:var(--rateu-muted,#77716a);white-space:normal;overflow-wrap:anywhere;font-style:normal;margin:0 26px 0 0;flex:1}
.dialog .filter-page--refined .field-counter{display:none!important}
.dialog .filter-page--refined .field-arrow{position:absolute;right:0;top:calc(50% - 9px);width:18px;height:18px;color:var(--rateu-muted,#77716a);transform:none}
.dialog .filter-page--refined .filter-gender select{width:100%;min-height:28px;padding:0;border:0;border-radius:0;background-color:transparent;color:var(--rateu-muted,#77716a);font:400 13px 'Rubik',sans-serif;box-shadow:none}
.dialog .filter-page--refined .filter-more{margin-top:18px;padding-top:14px;border-top:1px solid var(--rateu-line,#ded9d1)}
.dialog .filter-page--refined .filter-more summary{min-height:40px;font-size:13px;font-weight:500;cursor:pointer}
.dialog .filter-page--refined .filter-footer{margin:18px -16px -20px;padding:12px 16px calc(16px + env(safe-area-inset-bottom));border-top:0;background:var(--rateu-bg,#f7f3ec)}
.dialog .filter-page--refined .filter-apply{display:flex;align-items:center;justify-content:center;gap:10px;border:0;font:500 14px 'Rubik',sans-serif;text-transform:none;letter-spacing:0;box-shadow:2px 4px 0 var(--rateu-accent,#d31d29)}
.dialog .filter-page--refined .filter-apply svg{width:20px;height:20px}
.dialog .filter-page--refined .filter-error{padding:12px 0;margin:0;color:var(--rateu-accent,#d31d29);font-size:13px}
.dialog .filter-page--refined .filter-error[hidden]{display:none}
@media(max-width:370px){.dialog .filter-page--refined .filter-footer{margin-right:-12px;margin-left:-12px;padding-right:12px;padding-left:12px}}

/* Main form styling */
.dialog form {
    max-width: 800px;
    margin: 0 auto;
    font-family: Arial, sans-serif;
}

.dialog form table {
    width: 100%;
    border-collapse: collapse;
}

.dialog form tr {}

.dialog form tr:last-child {
    border-bottom: none;
}

.dialog form td {
    padding: 5px 10px;
    vertical-align: middle;
}

.dialog form td:first-child {
    width: 30%;
}

.dialog form label {
    font-weight: 500;
    color: #fff;
    font-size: 15px;
}

.dialog .emailSentStep form label {
    display: block;
    color: var(--rateu-ink, #191919);
}

.dialog select {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ddd;
    background-color: white;
    font-size: 14px;
    color: #333;
    appearance: none;
    background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%23333' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
    background-repeat: no-repeat;
    background-position: right 10px center;
    background-size: 15px;
}

.dialog select:focus {
    outline: none;
    border-color: #2196F3;
    box-shadow: 0 0 0 2px rgba(33, 150, 243, 0.2);
}


.dialog textarea,
.dialog input[type="text"]:not(.referral-input),
.dialog input[type="number"] {
    width: 100%;
    padding: 12px;
    border-radius: 8px;
    border: 1px solid #ddd;
    font-size: 14px;
    color: #333;
	box-sizing:border-box;
	line-height: 1.5;
	font-family: inherit;
	background:#fff;
}




.dialog input[type="text"]:focus,
.dialog input[type="number"]:focus {
    outline: none;
    border-color: #2196F3;
    box-shadow: 0 0 0 2px rgba(33, 150, 243, 0.2);
}

.settings input{
	margin-bottom:5px;
}

/* Height selector styles */
.height-selector {
    position: relative;
}

.height-ft-inputs {
    display: flex;
    align-items: center;
    gap: 10px;
}

.height-ft-inputs span {
    font-weight: 500;
    color: #666;
    min-width: 20px;
}

.height-ft-inputs input[type="number"] {
    width: 80px;
    padding: 12px;
}

.height-toggle {
    display: inline-block;
    margin-top: 10px;
    color: #2196F3;
    font-size: 14px;
    text-decoration: none;
    font-weight: 500;
}

.height-toggle:hover {
    text-decoration: underline;
}

/* Dialog save button styling */
.dialog-save-button-container {
    position: sticky;
    bottom: -23px;
    background-color: white;
    padding: 15px;
    box-shadow: 0 -4px 10px rgba(0, 0, 0, 0.1);
    margin: 20px -30px -60px -30px;
    text-align: center;
    z-index: 10;
}

.dialog-save-button {
    background-color: #2196F3;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 12px 40px;
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s, transform 0.1s;
    display: inline-block;
    min-width: 200px;
}

.dialog-save-button:hover {
    background-color: #0b7dda;
}

.dialog-save-button:active {
    transform: scale(0.98);
}

.dialog-save-button:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.3);
}

.dialog-save-button:disabled {
    background-color: #cccccc;
    cursor: not-allowed;
}

/* Hide old save buttons and fixed container */
.editRegister,
.editPhotosForm .save-button,
.editPhotosForm .fixed-save-container {
    display: none !important;
}
.registration .save-button{
	display:block !important;
}

/* Media preview size adjustment and responsive grid */
.photo-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 20px;
    max-width: 100%;
}

.photo-container {
    width: 100% !important;
    height: 0 !important;
    padding-bottom: 100% !important;
    position: relative;
    border-radius: 8px;
    overflow: hidden;
}

.photo-container img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

/* Styles for dragging photos on touch devices */
.photo-container.dragging-touch {
    opacity: 0.8;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
    cursor: grabbing !important;
    z-index: 999 !important;
    transform-origin: center center;
    position: absolute !important;
    max-width: 33.333% !important;
    /* Match the grid cell width */
    overflow: visible !important;
}

.photo-container.dragging-touch img {
    pointer-events: none;
    width: 100% !important;
    height: 100% !important;
    object-fit: cover !important;
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
}

.photo-container.empty {
    background-color: #f5f5f5;
    display: flex;
    align-items: center;
    justify-content: center;
}


/* Processing indicator when image is being resized */
.photo-container.processing {
    background: rgba(0, 0, 0, 0.7);
    display: flex;
    align-items: center;
    justify-content: center;
}

.photo-container .processing-indicator {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: white;
    gap: 8px;
}

.photo-container .processing-indicator i {
    font-size: 24px;
}

.photo-container .processing-indicator span {
    font-size: 12px;
    opacity: 0.8;
}

.add-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 24px;
    color: #999;
}

.remove-button {
    position: absolute;
    top: 5px;
    right: 5px;
    background-color: rgba(0, 0, 0, 0.6);
    color: white;
    border-radius: 50%;
    width: 24px;
    height: 24px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 14px;
}

.change-badge {
    position: absolute;
    bottom: 5px;
    right: 5px;
    background-color: #2196F3;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: none;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    font-weight: bold;
}

.change-badge.visible {
    display: flex;
}

/* Always display 3 media items per row on all devices */
.photo-grid {
    grid-template-columns: repeat(3, 1fr) !important;
}

/* Adjust spacing for small screens */
@media (max-width: 480px) {
    .photo-grid {
        gap: 6px;
    }

    /* Make UI elements smaller on mobile */
    .remove-button {
        width: 18px;
        height: 18px;
        font-size: 10px;
        top: 2px;
        right: 2px;
    }

    .change-badge {
        width: 16px;
        height: 16px;
        font-size: 10px;
        bottom: 2px;
        right: 2px;
    }

    .add-icon {
        font-size: 16px;
    }

    /* Adjust heading size for mobile */
    #editProfileDialog h2 {
        font-size: 18px;
        margin: 15px 0;
		font-weight:bold;
    }

    /* Adjust height inputs for mobile */
    .height-ft-inputs {
        gap: 5px;
    }

    .height-ft-inputs input[type="number"] {
        width: 60px;
        padding: 8px;
    }
}

/* Ensure minimal padding for extremely small screens */
@media (max-width: 360px) {
    .photo-grid {
        gap: 3px;
    }
}

/* Common upload overlay styles for both Media and Details */
.uploading-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    justify-content: center;
    align-items: center;
    flex-direction: column;
}

.uploading-spinner {
    width: 50px;
    height: 50px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

.uploading-overlay p {
    color: white;
    font-size: 16px;
}

/* Common notification style */
.notification {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    z-index: 2000;
    display: none;
    animation: slideIn 0.3s forwards;
}

.notification.success {
    background-color: #4CAF50;
    color: white;
}

.notification.error {
    background-color: #F44336;
    color: white;
}

@keyframes slideIn {
    from {
        transform: translateX(100%);
        opacity: 0;
    }

    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Section headings */
#editProfileDialog h2,#editProfile h2 {
    position: relative;
    color: #f4f4f4;
    font-size: 22px;
    font-weight: bold;
    margin: 20px 0;
}

#editProfileDialog .shufflePhotos{
	margin:-10px 0 22px 0;
}

/* No hint for touch rearranging - reverted to original state */

@media (min-width: 769px) {

    /* Hide the hint on desktop */
    .photo-grid::before {
        content: "";
        margin: 0;
        display: none;
    }
}

/* Loader animation */
/*
.loader {
    display: inline-block;
    width: 20px;
    height: 20px;
    border: 3px solid rgba(33, 150, 243, 0.3);
    border-radius: 50%;
    border-top-color: #2196F3;
    animation: spin 1s linear infinite;
    margin-left: 10px;
    vertical-align: middle;
}
*/

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* Success/Error messages */
.successMessage,
.errorMessage {
    padding: 10px 15px;
    border-radius: 8px;
    margin-top: 15px;
    font-size: 14px;
    display: none;
}

.successMessage {
    background-color: #e8f5e9;
    color: #2e7d32;
    border: 1px solid #c8e6c9;
}

.errorMessage {
    background-color: #ffebee;
    color: #c62828;
    border: 1px solid #ffcdd2;
}

/* Media query for mobile devices */
@media (max-width: 768px) {
    #editProfile td {
        display: block;
        width: 100%;
        padding: 2px 0;
    }

    #editProfile td:first-child {
        width: 100%;
        padding-bottom: 0;
    }

    #editProfile tr {
        margin-bottom: 5px;
        display: block;
    }
}

/* Styles for popup selection modal */
#editProfile td.hiddenCheckbox{display:none;}
.checkbox-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    z-index: 1000;
    justify-content: center;
    align-items: center;
}

.checkbox-modal-content {
    background-color: white;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    max-height: 90vh;
    overflow-y: auto;
    padding: 20px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
    position: relative;
}

.checkbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-bottom: 5px;
	padding-top: 6px;
    border-bottom: 1px solid #eee;
    margin-bottom: 15px;
}

.checkbox-title {
    font-family: 'Rubik', sans-serif;
    font-size: 16px;
    font-weight: 700;
    line-height: 1.3;
    margin: 0;
}

.checkbox-close {
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #999;
}

.checkbox-search {
    width: 100%;
    padding: 10px;
    margin-bottom: 15px;
    border: 1px solid #ddd;
    border-radius: 8px;
    font-size: 16px;
	box-sizing:border-box;
}

.checkbox-options {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 20px;
	color:#000;
}

.checkbox-option {
    background-color: #f0f0f0;
    border: 1px solid #ddd;
    border-radius: 20px;
    padding: 8px 16px;
    cursor: pointer;
    transition: all 0.2s;
}

.checkbox-option.selected {
    background-color: #e0f0ff;
    border-color: #2196F3;
    color: #2196F3;
}

.checkbox-footer {
    display: flex;
    justify-content: flex-end;
    padding-top: 15px;
    border-top: 1px solid #eee;
}

.done-button {
    background-color: #2196F3;
    color: white;
    border: none;
    border-radius: 8px;
    padding: 10px 20px;
    font-size: 16px;
    cursor: pointer;
}

.done-button:hover {
    background-color: #0b7dda;
}

/* Styles for field summary display */
.field-summary {
    display: flex;
    align-items: center;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.field-summary:hover {
    background-color: #333232;
}

.field-icon {
    color: #666;
    margin-right: 10px;
    font-size: 20px;
}

.field-values {
    flex-grow: 1;
}

.field-empty {
    color: #999;
}

.field-arrow {
    color: #999;
    margin-left: 10px;
}

.field-counter {
    background-color: #e0f0ff;
    color: #2196F3;
    border-radius: 12px;
    padding: 2px 8px;
    font-size: 12px;
    margin-left: 10px;
}

/* Birthdate selector */
.birthdate-group {
    display: flex;
    gap: 8px;
    width: 100%;
}

.birthdate-group .birth-input {
    flex: 1;
    /* uses your existing select styles */
}

.birthdate-group .birth-year {
    flex: 1.4; /* year a bit wider */
}

.birthnote {
    display: block;
    margin-top: 6px;
    font-size: 12px;
    color: #ccc;
}

.birthdate-row td {
    padding-top: 10px;
    display: block;
    width: 100%;
}

/* RateU 2026 profile editor ------------------------------------------------- */
.profile-edit-page {
    width: calc(100% + 50px);
    min-height: 100%;
    box-sizing: border-box;
    margin: 0 -25px;
    padding: 0 16px 40px;
    background: var(--rateu-bg, #f7f3ec);
    color: var(--rateu-ink, #191919);
    font-family: 'Rubik', ui-sans-serif, system-ui, sans-serif;
}

.profile-edit-header {
    position: sticky;
    top: 0;
    z-index: 100;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 64px;
    margin: 0 -16px 14px;
    padding: 0 16px;
    border-bottom: 1px solid var(--rateu-line, #ded9d1);
    background: rgba(247, 243, 236, .98);
}

.profile-edit-header .backBtn {
    display: grid;
    width: 40px;
    height: 40px;
    box-sizing: border-box;
    place-items: center;
    padding: 8px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--rateu-ink, #191919);
    cursor: pointer;
}

.profile-edit-header h1 {
    margin: 0;
    color: var(--rateu-ink, #191919);
    font-family: 'Lilita One','RateU Caron', 'Rubik', sans-serif;
    font-size: 27px;
    font-weight: 400;
    line-height: 1;
    letter-spacing: -.025em;
    text-transform: uppercase;
}

.profile-edit-save {
    min-height: 38px;
    padding: 0 16px;
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    background: oklch(99% 0.005 60);
    color: var(--rateu-ink, #191919);
    box-shadow: 2px 2px 0 var(--rateu-ink, #191919);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
    cursor: pointer;
    transition:
        transform 150ms cubic-bezier(0.4, 0, 0.2, 1),
        translate 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.profile-edit-save:active {
    translate: 2px 2px;
}

.profile-edit-page #editProfile {
    max-width: 650px;
    padding-bottom: 25px;
    color: var(--rateu-ink, #191919);
    font-family: inherit;
}

.profile-edit-page #editProfileDialog h2,
.profile-edit-page #editProfile > h2 {
    margin: 18px 0 11px;
    color: var(--rateu-ink, #191919);
    font-family: 'Lilita One','RateU Caron', 'Rubik', sans-serif;
    font-size: 22px;
    font-weight: 400;
    letter-spacing: .01em;
    text-transform: uppercase;
}

.profile-edit-page .photo-grid {
    gap: 10px;
    margin-bottom: 12px;
}

.profile-edit-page .photo-container {
    border: 1px solid var(--rateu-line, #ded9d1);
    border-radius: 14px;
    background: #fff;
    box-shadow: 0 4px 12px rgba(25, 25, 25, .05);
}

.profile-edit-page .photo-container.empty {
    border: 1.5px dashed #c9c1b7;
    background: rgba(255, 255, 255, .55);
    box-shadow: none;
}

.profile-edit-page .add-icon {
    color: #817a72;
    font-size: 25px;
}

.profile-edit-page .remove-button {
    top: 0;
    right: 0;
    display: grid;
    width: 44px;
    height: 44px;
    place-items: center;
    padding: 0;
    border: 0;
    background: transparent;
    color: var(--rateu-ink, #191919);
    font-size: 12px;
    font-weight: 800;
    box-shadow: none;
    cursor: pointer;
}

.profile-edit-page .remove-button::before {
    content: '';
    position: absolute;
    width: 28px;
    height: 28px;
    border: 1.5px solid var(--rateu-ink, #191919);
    border-radius: 50%;
    background: #fff;
    box-shadow: 2px 2px 0 rgba(25, 25, 25, .28);
}

.profile-edit-page .remove-button i {
    position: relative;
    z-index: 1;
}

.profile-edit-page .photo-verified-badge {
    position: absolute;
    left: 6px;
    bottom: 6px;
    display: grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #fff;
    color: #174998;
    box-shadow: 0 1px 5px rgba(25, 25, 25, .3);
    font-size: 16px;
    font-weight: 800;
    pointer-events: none;
}

.verified-photo-removal {
    box-sizing: border-box;
    width: min(380px, calc(100% - 32px));
    padding: 22px;
    border: 1px solid var(--rateu-line, #ded9d1);
    border-radius: 20px;
    background: #f7f3ec;
    color: var(--rateu-ink, #191919);
}

.verified-photo-removal::backdrop {
    background: rgba(25, 25, 25, .52);
}

.verified-photo-removal h2 {
    margin: 0 0 10px;
    font-size: 20px;
}

.verified-photo-removal p {
    margin: 0;
    line-height: 1.5;
}

.verified-photo-removal-actions {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-end;
    gap: 8px;
    margin-top: 20px;
}

.verified-photo-removal-actions button {
    min-height: 44px;
    padding: 8px 14px;
    border: 1px solid var(--rateu-ink, #191919);
    border-radius: 24px;
    background: #fff;
    color: inherit;
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.verified-photo-removal-actions button[value="remove"] {
    background: #a6252d;
    border-color: #a6252d;
    color: #fff;
}

.profile-edit-save:disabled {
    cursor: wait;
    opacity: .72;
}

.photoUndo {
    position: fixed;
    z-index: 2200;
    left: 50%;
    bottom: calc(18px + env(safe-area-inset-bottom));
    display: flex;
    width: min(360px, calc(100% - 28px));
    min-height: 50px;
    box-sizing: border-box;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 9px 10px 9px 15px;
    border: 1px solid rgba(255, 255, 255, .14);
    border-radius: 14px;
    background: #242321;
    color: #fff;
    box-shadow: 0 14px 32px rgba(0, 0, 0, .22);
    font-size: 12px;
    transform: translate(-50%, 24px);
    opacity: 0;
    pointer-events: none;
    transition: opacity .18s ease, transform .18s ease;
}

.photoUndo.visible {
    transform: translate(-50%, 0);
    opacity: 1;
    pointer-events: auto;
}

.photoUndo button {
    min-height: 34px;
    padding: 0 12px;
    border: 0;
    border-radius: 999px;
    background: #fff;
    color: #242321;
    font-family: inherit;
    font-size: 11px;
    font-weight: 800;
    cursor: pointer;
}

.profile-edit-page .shufflePhotos {
    display: flex;
    align-items: flex-start;
    gap: 7px;
    margin: 0 0 22px;
    color: #68625c;
    font-size: 12px;
    line-height: 1.4;
}

.profile-edit-page .shufflePhotos input { margin-top: 2px; }

.profile-edit-page #match {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 16px;
    border: 1px solid rgba(25, 25, 25, .08);
    border-radius: 20px;
    background: #fff;
}

.profile-edit-page #match tbody,
.profile-edit-page #match tr { width: 100%; }

.profile-edit-page #match > tbody { display: table; }

.profile-edit-page #editProfile td { box-sizing: border-box; }

.profile-edit-page #editProfile label {
    color: #4d4945;
    font-size: 13px;
    font-weight: 700;
}

.profile-edit-page #editProfile select,
.profile-edit-page #editProfile textarea,
.profile-edit-page #editProfile input[type="text"]:not(.referral-input),
.profile-edit-page #editProfile input[type="number"],
.profile-edit-page .field-summary {
    min-height: 50px;
    box-sizing: border-box;
    border: 1.5px solid #cfc8c0;
    border-radius: 12px;
    background-color: #fff;
    color: var(--rateu-ink, #191919);
    font-family: inherit;
    font-size: 14px;
}

.profile-edit-page #editProfile textarea {
    min-height: 112px;
    line-height: 1.5;
}

.profile-edit-page #editProfile select:focus,
.profile-edit-page #editProfile textarea:focus,
.profile-edit-page #editProfile input[type="text"]:focus,
.profile-edit-page #editProfile input[type="number"]:focus,
.profile-edit-page .field-summary:focus-within {
    outline: none;
    border-color: var(--rateu-ink, #191919);
    box-shadow: 0 0 0 3px rgba(255, 81, 85, .14);
}

.profile-edit-page .height-toggle {
    display: inline-block;
    margin-top: 7px;
    color: var(--rateu-accent, #ff5155);
    font-size: 12px;
    font-weight: 600;
}

.profile-edit-page .field-icon,
.profile-edit-page .field-arrow { color: #77716a; }
.profile-edit-page .field-counter { background: #fff0ed; color: #c8393e; }
.profile-edit-page .birthnote { color: #8b857f; }

.profile-edit-page .editRegister { display: none !important; }

.checkbox-modal-content {
    border: 1px solid var(--rateu-line, #ded9d1);
    border-radius: 20px;
    background: var(--rateu-bg, #f7f3ec);
    color: var(--rateu-ink, #191919);
}

.checkbox-header .backBtn {
    position: static;
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    color: var(--rateu-ink, #191919);
}

.checkbox-header .backBtn svg {
    fill: currentColor;
}

.checkbox-option {
    border-color: var(--rateu-line, #ded9d1);
    background: #fff;
}

.checkbox-option.selected {
    border-color: var(--rateu-ink, #191919);
    background: #fff0ed;
    color: #c8393e;
}

.done-button {
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    background: var(--rateu-ink, #191919);
    color: #fff;
    box-shadow: 3px 3px 0 var(--rateu-accent, #ff5155);
}

@media (max-width: 768px) {
    .profile-edit-page #match { padding: 14px; }
    .profile-edit-page #match > tbody { display: block; }
    .profile-edit-page #editProfile tr { margin: 0 0 14px; }
    .profile-edit-page #editProfile tr:last-child { margin-bottom: 0; }
    .profile-edit-page #editProfile td { padding: 2px 0; }
    .profile-edit-page #editProfile td:first-child { padding-bottom: 6px; }
    .profile-edit-page #editProfile tr.profile-looking-for-row { margin-bottom: 4px; }
    .profile-edit-page #editProfile tr.profile-no-ons-row > td:first-child { display: none; }
}

@media (max-width: 360px) {
    .profile-edit-page { padding-right: 12px; padding-left: 12px; }
    .profile-edit-header { margin-right: -12px; margin-left: -12px; padding-right: 12px; padding-left: 12px; }
    .profile-edit-header h1 { font-size: 24px; }
    .profile-edit-save { padding-right: 13px; padding-left: 13px; }
    .profile-edit-page .photo-grid { gap: 6px; }
}

/* RateU 2026 search filters ---------------------------------------------- */
.filter-page,
.settings-page {
    width: calc(100% + 50px);
    min-height: 100%;
    box-sizing: border-box;
    margin: 0 -25px;
    padding: 0 16px 36px;
    background: var(--rateu-bg, #f7f3ec);
    color: var(--rateu-ink, #191919);
    font-family: 'Rubik', ui-sans-serif, system-ui, sans-serif;
}

.filter-header,
.settings-header {
    position: sticky;
    top: 0;
    z-index: 100;
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 8px;
    min-height: 64px;
    margin: 0 -16px 14px;
    padding: 0 16px;
    border-bottom: 1px solid var(--rateu-line, #ded9d1);
    background: rgba(247, 243, 236, .98);
}

.filter-back,
.settings-back {
    display: grid;
    width: 40px;
    height: 40px;
    box-sizing: border-box;
    place-items: center;
    padding: 8px;
    border: 0;
    border-radius: 50%;
    background: transparent;
    color: var(--rateu-ink, #191919);
    cursor: pointer;
}

.filter-back svg,
.settings-back svg { fill: currentColor; }

.filter-header h1,
.settings-header h1 {
    margin: 0;
    color: var(--rateu-ink, #191919);
    font-family: 'Lilita One','RateU Caron', 'Rubik', sans-serif;
    font-size: 27px;
    font-weight: 400;
    line-height: 1;
    letter-spacing: -.025em;
    text-transform: uppercase;
}

.filter-header-apply {
    min-height: 38px;
    padding: 0 16px;
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    background: oklch(99% 0.005 60);
    color: var(--rateu-ink, #191919);
    box-shadow: 2px 2px 0 var(--rateu-ink, #191919);
    font-size: 11px;
    font-weight: 900;
    letter-spacing: .04em;
    text-transform: uppercase;
    cursor: pointer;
    transition:
        transform 150ms cubic-bezier(0.4, 0, 0.2, 1),
        translate 150ms cubic-bezier(0.4, 0, 0.2, 1);
}

.filter-header-apply:active {
    translate: 2px 2px;
}

.filter-apply:active,
.settings-primary:active,
.settings-secondary:active,
.settings-danger-button:active {
    transform: translate(4px, 4px);
    box-shadow: none;
}

.dialog .filter-form {
    width: 100%;
    max-width: 650px;
    padding-bottom: 0;
    color: var(--rateu-ink, #191919);
    font-family: inherit;
}

.filter-page #match {
    display: block;
    width: 100%;
    overflow: hidden;
    box-sizing: border-box;
    border: 1px solid rgba(25, 25, 25, .08);
    border-radius: 20px;
    background: #fff;
}

.filter-page #match tbody { display: block; width: 100%; }

.filter-page #match tr {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    width: 100%;
    box-sizing: border-box;
    padding: 15px;
    border-bottom: 1px solid var(--rateu-line, #ded9d1);
}

.filter-page #match tr:last-child { border-bottom: 0; }

.dialog .filter-page #match td,
.dialog .filter-page #match td:first-child {
    display: block;
    width: 100%;
    box-sizing: border-box;
    padding: 0;
}

.dialog .filter-page #match td:first-child { margin-bottom: 9px; }

.dialog .filter-page #match td:first-child > label {
    color: #4d4945;
    font-size: 13px;
    font-weight: 800;
    letter-spacing: .01em;
}

.filter-page select,
.filter-page .field-summary {
    width: 100%;
    min-height: 48px;
    box-sizing: border-box;
    border: 1.5px solid #cfc8c0;
    border-radius: 13px;
    background-color: #fff;
    color: var(--rateu-ink, #191919);
    font-family: inherit;
    font-size: 14px;
}

.filter-page .field-summary {
    display: flex;
    align-items: center;
    padding: 11px 13px;
}

.filter-page .field-summary:hover { background: #fff9f7; }
.filter-page .field-icon,
.filter-page .field-arrow { color: #77716a; }
.filter-page .field-counter { background: #fff0ed; color: #c8393e; }

.filter-page #slider-container,
.filter-page #slider-container2 {
    width: calc(100% - 4px);
    max-width: none;
    margin: 13px 2px 0;
}

.filter-page #slider-container2 { margin-top: 4px; }

.filter-page .ui-slider {
    height: 8px;
    border: 0;
    border-radius: 999px;
    background: #e5dfd7;
}

.filter-page .ui-slider .ui-slider-range {
    border: 0;
    border-radius: 999px;
    background: var(--rateu-accent, #ff5155);
}

.filter-page .ui-slider .ui-slider-handle {
    top: 50%;
    width: 23px;
    height: 23px;
    box-sizing: border-box;
    margin-left: -11px;
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 50%;
    background: #fff;
    box-shadow: 2px 2px 0 var(--rateu-accent, #ff5155);
    transform: translateY(-50%);
    cursor: grab;
}

.filter-page .selectedValue {
    margin: 17px 0 0;
    color: #77716a;
    font-size: 12px;
    line-height: 1.4;
}

.filter-page .selectedValue span { color: var(--rateu-ink, #191919); font-weight: 800; }
.filter-page .unit-toggle { margin-top: 10px; }

.filter-page .btn-small {
    min-height: 34px;
    padding: 0 13px;
    border: 1.5px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    background: #fff;
    color: var(--rateu-ink, #191919);
    font-size: 11px;
    font-weight: 750;
    cursor: pointer;
}

.filter-page #match td:not(:first-child) > label {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    min-height: 36px;
    box-sizing: border-box;
    margin: 3px 4px 3px 0;
    padding: 6px 11px;
    border: 1px solid var(--rateu-line, #ded9d1);
    border-radius: 999px;
    background: #fff;
    color: var(--rateu-ink, #191919);
    font-size: 12px;
}

.filter-page #match td:not(:first-child) > label:has(input:checked) {
    border-color: var(--rateu-ink, #191919);
    background: #fff0ed;
    color: #c8393e;
}

.filter-page #match input[type="checkbox"] { accent-color: var(--rateu-accent, #ff5155); }

.filter-footer {
    position: sticky;
    bottom: 0;
    z-index: 80;
    margin: 12px -16px -36px;
    padding: 12px 16px calc(16px + env(safe-area-inset-bottom));
    border-top: 1px solid var(--rateu-line, #ded9d1);
    background: rgba(247, 243, 236, .97);
}

.filter-apply {
    width: 100%;
    min-height: 50px;
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    background: var(--rateu-ink, #191919);
    color: #fff;
    box-shadow: 4px 4px 0 var(--rateu-accent, #ff5155);
    font-size: 13px;
    font-weight: 900;
    letter-spacing: .03em;
    text-transform: uppercase;
    cursor: pointer;
}

/* RateU 2026 settings ----------------------------------------------------- */
.settings-header { grid-template-columns: 42px minmax(0, 1fr) 42px; }
.settings-header-spacer { width: 42px; }

.settings-content {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
    width: 100%;
    max-width: 650px;
    margin: 0 auto;
}

.settings-card {
    box-sizing: border-box;
    padding: 17px;
    border: 1px solid rgba(25, 25, 25, .09);
    border-radius: 20px;
    background: #fff;
    color: var(--rateu-ink, #191919);
}

.settings-card h2 {
    margin: 0 0 5px;
    color: var(--rateu-ink, #191919);
    font-family: 'Lilita One','RateU Caron', 'Rubik', sans-serif;
    font-size: 20px;
    font-weight: 400;
    letter-spacing: .01em;
    text-transform: uppercase;
}

.settings-card p {
    margin: 0;
    color: #6f6962;
    font-size: 12px;
    line-height: 1.55;
    overflow-wrap: anywhere;
}

.settings-card-heading {
    display: grid;
    grid-template-columns: 38px minmax(0, 1fr);
    align-items: start;
    gap: 10px;
}

.settings-card-icon {
    display: grid;
    width: 36px;
    height: 36px;
    place-items: center;
    border: 1.5px solid var(--rateu-ink, #191919);
    border-radius: 50%;
    background: #fff0ed;
    color: #c8393e;
    font-size: 17px;
    font-weight: 900;
}

.settings-field-group,
.settings-confirm-box {
    display: grid;
    gap: 8px;
    margin-top: 16px;
}

.settings-card label {
    color: #4d4945;
    font-size: 12px;
    font-weight: 800;
}

.dialog .settings-page input[type="text"],
.dialog .settings-page input[type="email"] {
    width: 100%;
    min-height: 48px;
    box-sizing: border-box;
    margin: 0;
    padding: 0 13px;
    border: 1.5px solid #cfc8c0;
    border-radius: 13px;
    background: #fff;
    color: var(--rateu-ink, #191919);
    font-family: inherit;
    font-size: 14px;
}
.dialog .settings-page select { width:100%; min-height:48px; padding:0 13px; border:1.5px solid #cfc8c0; border-radius:13px; background:#fff; color:var(--rateu-ink, #191919); font-family:inherit; font-size:14px; }
.settings-deactivate-card { display:grid; gap:12px; border-color:rgba(177,132,48,.35); background:#fffaf0; }

.dialog .settings-page input:focus {
    outline: none;
    border-color: var(--rateu-ink, #191919);
    box-shadow: 0 0 0 3px rgba(255, 81, 85, .14);
}

.settings-primary,
.settings-secondary,
.settings-danger-button {
    min-height: 44px;
    padding: 0 17px;
    border: 2px solid var(--rateu-ink, #191919);
    border-radius: 999px;
    font-size: 12px;
    font-weight: 900;
    letter-spacing: .03em;
    text-transform: uppercase;
    cursor: pointer;
}

.settings-primary {
    justify-self: start;
    background: var(--rateu-ink, #191919);
    color: #fff;
    box-shadow: 4px 4px 0 var(--rateu-accent, #ff5155);
}

.settings-logout-card,
.settings-legal-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
}

.settings-secondary {
    flex: 0 0 auto;
    background: #fff;
    color: var(--rateu-ink, #191919);
    box-shadow: 3px 3px 0 #bdb5ab;
}

.settings-danger-card {
    border-color: rgba(195, 51, 57, .3);
    background: #fff7f5;
}

.settings-danger-card strong { color: #9f252b; }

.settings-card .settings-appeals-warning {
    margin: 12px 0;
    padding: 12px;
    border-left: 3px solid #a72c31;
    border-radius: 8px;
    background: #ffe8e2;
    color: #812126;
    font-weight: 600;
}

.settings-danger-button {
    width: 100%;
    margin-top: 10px;
    border-color: #a72c31;
    background: #a72c31;
    color: #fff;
    box-shadow: 4px 4px 0 var(--rateu-ink, #191919);
}

.settings-legal-link {
    flex: 0 0 auto;
    color: var(--rateu-ink, #191919);
    font-size: 12px;
    font-weight: 800;
    text-decoration: none;
    white-space: nowrap;
}

.settings-legal-link span { color: var(--rateu-accent, #ff5155); font-size: 20px; vertical-align: -2px; }
.settings-response { color: #2e7545 !important; font-weight: 700; }

@media (max-width: 360px) {
    .filter-page,
    .settings-page { padding-right: 12px; padding-left: 12px; }
    .filter-header,
    .settings-header { margin-right: -12px; margin-left: -12px; padding-right: 12px; padding-left: 12px; }
    .filter-header h1,
    .settings-header h1 { font-size: 24px; }
    .filter-header-apply { padding-right: 13px; padding-left: 13px; }
    .filter-footer { margin-right: -12px; margin-left: -12px; padding-right: 12px; padding-left: 12px; }
    .settings-logout-card,
    .settings-legal-card { align-items: flex-start; flex-direction: column; }
}

/* Keep translated titles inside their column without truncation. */
.profile-edit-header h1 {
    min-width:0;
    overflow-wrap:anywhere;
    hyphens:auto;
}
