:root {
    --ink: #062e53;
    --ink-soft: #0a4876;
    --ink-deep: #041d34;
    --line: #176d9f;
    --surface: #0c5c91;
    --surface-active: #147bb4;
    --paper: #ffffff;
    --muted: #b5c8d8;
    --muted-dark: #7f9eb6;
    --accent: #ff941d;
    --green: #4ade80;
    --danger: #ff8a8a;
    --shadow: 0 22px 60px rgba(1, 24, 44, .3);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; margin: 0; }
body {
    min-height: 100dvh;
    color: var(--paper);
    background: var(--ink);
    font-family: "DM Sans", Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}
button, input { font: inherit; }
button { cursor: pointer; }
button:disabled, input:disabled { cursor: not-allowed; opacity: .55; }

/* Authentication */
.auth-container {
    display: grid;
    min-height: 100dvh;
    place-items: center;
    padding: 24px;
    background:
        radial-gradient(circle at 15% 12%, rgba(144, 94, 54, .35), transparent 36%),
        var(--ink-deep);
}
.auth-card {
    width: min(100%, 420px);
    padding: 38px;
    border: 1px solid var(--line);
    border-radius: 26px;
    color: var(--paper);
    background: var(--ink-soft);
    box-shadow: var(--shadow);
}
.auth-card h2 { margin: 0; font-size: 1.8rem; letter-spacing: -.045em; }
.auth-card > p { margin: 10px 0 28px; color: var(--muted); }
.form-group { margin-bottom: 18px; }
.form-group label { display: block; margin-bottom: 8px; color: #f2e8e1; font-size: .88rem; font-weight: 700; }
.form-group input {
    width: 100%; height: 48px; padding: 0 14px; border: 1px solid var(--line); border-radius: 12px;
    outline: none; color: var(--paper); background: var(--ink-deep);
}
.form-group input:focus { border-color: #9a7252; box-shadow: 0 0 0 3px rgba(240,195,157,.12); }
.btn {
    width: 100%; height: 48px; border: 0; border-radius: 12px; color: var(--ink);
    background: var(--paper); font-weight: 800; transition: .2s ease;
}
.btn:hover { background: #f0c39d; transform: translateY(-1px); }
.bottom-text { margin-top: 22px; color: var(--muted); font-size: .9rem; text-align: center; }
.bottom-text a { color: #f0c39d; font-weight: 700; text-decoration: none; }
.remember-login { display: flex; align-items: center; gap: 8px; margin: 13px 0 0; color: var(--muted); font-size: .84rem; cursor: pointer; }.remember-login input { accent-color: var(--accent); }.auth-divider { display: flex; align-items: center; gap: 12px; margin: 20px 0; color: var(--muted); font-size: .8rem; }.auth-divider::before, .auth-divider::after { flex: 1; height: 1px; background: var(--line); content: ''; }.google-login { display: flex; align-items: center; justify-content: center; gap: 10px; min-height: 46px; border: 1px solid var(--line); border-radius: 12px; color: var(--paper); font-weight: 800; background: rgba(255,255,255,.03); }.google-login:hover { background: rgba(255,255,255,.08); }.google-login svg { width: 20px; height: 20px; }
#message { min-height: 20px; margin: 14px 0 0; color: var(--danger); font-size: .87rem; text-align: center; }

.chat-app { display: flex; min-height: 100dvh; overflow: hidden; }
.sidebar {
    width: min(380px, 31vw);
    min-width: 320px;
    display: flex;
    flex-direction: column;
    background: var(--ink);
    border-right: 1px solid var(--ink-soft);
}
.sidebar-header { display: flex; align-items: center; justify-content: space-between; padding: 28px 22px 22px; }
.brand { color: var(--paper); text-decoration: none; font-size: 1.7rem; font-weight: 800; letter-spacing: -.06em; }
.header-actions { display: flex; gap: 12px; align-items: center; }
.icon-button, .profile-avatar, .send-button {
    display: grid; place-items: center; flex: 0 0 auto; width: 42px; height: 42px;
    border: 1px solid rgba(255,255,255,.12); border-radius: 50%; color: var(--paper);
    background: rgba(255,255,255,.09); transition: .2s ease;
}
.icon-button:hover, .profile-avatar:hover { transform: translateY(-1px); background: rgba(255,255,255,.16); }
.icon-button svg, .send-button svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.profile-avatar { overflow: hidden; border: 0; color: var(--ink); background: var(--accent); font-size: .9rem; font-weight: 800; }
.profile-avatar img { width: 100%; height: 100%; object-fit: cover; }
.search-wrap { position: relative; margin: 0 22px 12px; }
.search-wrap input {
    width: 100%; height: 52px; padding: 0 16px 0 48px; color: var(--paper); outline: none;
    border: 1px solid var(--line); border-radius: 999px; background: var(--ink-deep);
}
.search-wrap input::placeholder { color: var(--muted-dark); }
.search-wrap input:focus { border-color: #9a7252; box-shadow: 0 0 0 3px rgba(240, 195, 157, .12); }
.search-icon { position: absolute; width: 20px; height: 20px; left: 17px; top: 16px; fill: none; stroke: var(--muted); stroke-width: 2; }
.connection-bar { min-height: 24px; padding: 2px 23px 10px; color: var(--muted); font-size: .72rem; }
.connection-bar.connected { color: var(--green); }
.user-list { flex: 1; overflow-y: auto; padding: 3px 10px 16px; scrollbar-color: var(--line) transparent; }
.user-item {
    width: 100%; display: flex; align-items: center; gap: 13px; padding: 12px; border: 1px solid transparent;
    border-radius: 18px; color: var(--paper); background: transparent; text-align: left; transition: .2s ease;
}
.user-item:hover { background: rgba(255,255,255,.07); }
.user-item.active-chat { background: var(--surface-active); border-color: rgba(255,255,255,.28); }
.user-avatar, .recipient-avatar {
    width: 52px; height: 52px; border-radius: 50%; object-fit: cover; color: var(--ink);
    background: #efc5a2; display: grid; place-items: center; font-weight: 800; flex: 0 0 auto;
}
.user-info { min-width: 0; flex: 1; }
.user-top, .user-bottom { display: flex; align-items: center; gap: 8px; }
.user-top { justify-content: space-between; }
.user-top strong { overflow: hidden; font-size: .98rem; text-overflow: ellipsis; white-space: nowrap; }
.user-time { flex: 0 0 auto; color: var(--muted); font-size: .73rem; }
.user-bottom { margin-top: 5px; }
.last-message { overflow: hidden; color: #d4ccc7; font-size: .86rem; text-overflow: ellipsis; white-space: nowrap; }
.status-dot { width: 9px; height: 9px; flex: 0 0 auto; border: 2px solid var(--ink); border-radius: 50%; background: #777; }
.status-dot.online { background: var(--green); }
.unread-badge {
    display: grid; min-width: 22px; height: 22px; padding: 0 6px; place-items: center;
    border-radius: 999px; color: var(--ink); background: var(--paper); font-size: .7rem; font-weight: 800;
}

.notification-button { position: relative; }
.notification-badge, .request-badge {
    position: absolute; top: -5px; right: -6px; min-width: 18px; height: 18px; padding: 0 4px;
    display: grid; place-items: center; border: 2px solid var(--ink); border-radius: 999px;
    color: var(--ink); background: #f0c39d; font-size: .62rem; font-weight: 900;
}
.overlay { position: fixed; z-index: 24; inset: 0; background: rgba(0,0,0,.42); backdrop-filter: blur(2px); }
.notification-panel {
    position: fixed; z-index: 25; top: 18px; right: 18px; bottom: 18px; width: min(410px, calc(100vw - 36px));
    display: flex; flex-direction: column; overflow: hidden; border: 1px solid var(--line); border-radius: 25px;
    color: var(--paper); background: var(--ink-soft); box-shadow: var(--shadow);
}
.notification-panel[hidden], .overlay[hidden] { display: none !important; }
.notification-panel-header { display: flex; align-items: center; justify-content: space-between; padding: 22px 20px 13px; border-bottom: 1px solid rgba(255,255,255,.08); }
.notification-panel-header h2 { margin: 2px 0 0; font-size: 1.25rem; }
.eyebrow { margin: 0; color: #f0c39d; font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; }
.notification-tools, .notification-footer { padding: 12px 20px; border-bottom: 1px solid rgba(255,255,255,.08); }
.notification-footer { border-top: 1px solid rgba(255,255,255,.08); border-bottom: 0; }
.text-button { padding: 0; border: 0; color: #f0c39d; background: none; font-weight: 800; }
.notification-list { min-height: 0; flex: 1; overflow-y: auto; padding: 8px; scrollbar-color: var(--line) transparent; }
.notification-item { display: grid; gap: 12px; padding: 15px 13px; border: 1px solid transparent; border-radius: 16px; cursor: pointer; }
.notification-item:hover, .notification-item:focus-visible { border-color: rgba(255,255,255,.17); outline: none; background: rgba(255,255,255,.055); }
.notification-item.unread { border-color: rgba(240,195,157,.2); background: rgba(240,195,157,.08); }
.notification-copy strong { font-size: .92rem; }.notification-copy p { margin: 4px 0; color: #ded2ca; font-size: .87rem; line-height: 1.35; }.notification-copy time { color: var(--muted); font-size: .72rem; }
.notification-actions { display: flex; gap: 8px; }.small-primary, .small-secondary { min-height: 34px; padding: 0 12px; border-radius: 10px; font-weight: 800; }.small-primary { border: 0; color: var(--ink); background: var(--paper); }.small-secondary { border: 1px solid var(--line); color: var(--paper); background: transparent; }.notification-empty { margin: 34px 0; color: var(--muted); text-align: center; }

/* Profiles */
.profile-page { min-height: 100dvh; background: radial-gradient(circle at 20% 0%, rgba(20,137,203,.26), transparent 32%), var(--ink-deep); }
.profile-shell { width: min(100% - 32px, 760px); margin: 0 auto; padding: max(18px, env(safe-area-inset-top)) 0 max(32px, env(safe-area-inset-bottom)); }
.profile-topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }.profile-topbar .brand { font-size: 1.35rem; }
.profile-search { position: relative; margin: 0 0 16px; }.profile-search > label { display: block; margin: 0 0 8px; color: var(--muted); font-size: .82rem; font-weight: 800; }.profile-search-input { position: relative; }.profile-search-input svg { position: absolute; top: 14px; left: 14px; width: 19px; height: 19px; fill: none; stroke: var(--muted); stroke-width: 2; }.profile-search-input input { width: 100%; height: 48px; padding: 0 14px 0 43px; border: 1px solid var(--line); border-radius: 14px; outline: none; color: var(--paper); background: var(--ink-soft); }.profile-search-input input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,148,29,.16); }.profile-search-results { max-height: 330px; margin-top: 8px; overflow-y: auto; border: 1px solid var(--line); border-radius: 16px; color: var(--muted); background: var(--ink-soft); }.profile-search-result { display: flex; align-items: center; gap: 11px; padding: 11px; border-bottom: 1px solid rgba(255,255,255,.08); color: var(--paper); text-decoration: none; }.profile-search-result:last-child { border-bottom: 0; }.profile-search-result:hover { background: rgba(255,255,255,.07); }.profile-search-result img { width: 42px; height: 42px; border-radius: 50%; object-fit: cover; }.profile-search-result span { display: grid; gap: 2px; }.profile-search-result small { color: var(--muted); }
.profile-card { min-height: 320px; padding: clamp(22px, 5vw, 44px); border: 1px solid var(--line); border-radius: 28px; background: var(--ink-soft); box-shadow: var(--shadow); }
.profile-loading { margin: 80px 0; color: var(--muted); text-align: center; }.profile-hero { display: flex; align-items: center; gap: 22px; }.profile-hero h1 { margin: 4px 0; font-size: clamp(1.55rem, 5vw, 2.2rem); letter-spacing: -.05em; }.profile-hero p { margin: 0; color: var(--muted); }.profile-image, .avatar-editor img { width: 94px; height: 94px; border-radius: 50%; object-fit: cover; background: var(--surface); }.avatar-editor { position: relative; cursor: pointer; }.avatar-editor span { position: absolute; right: -4px; bottom: 0; padding: 5px 8px; border-radius: 999px; color: var(--ink); background: #f0c39d; font-size: .68rem; font-weight: 800; }
.privacy-pill { display: inline-flex; margin-left: 5px; padding: 3px 7px; border-radius: 999px; color: #f0c39d; background: rgba(240,195,157,.12); font-size: .7rem; font-weight: 800; }.privacy-pill.public { color: var(--green); background: rgba(74,222,128,.12); }
.profile-form { display: grid; gap: 18px; margin-top: 36px; }.profile-form label { display: grid; gap: 8px; color: #f1e5dc; font-size: .85rem; font-weight: 800; }.profile-form input:not([type="checkbox"]), .profile-form textarea, .profile-form select { width: 100%; padding: 12px 13px; border: 1px solid var(--line); border-radius: 12px; outline: none; resize: vertical; color: var(--paper); background: var(--ink-deep); }.profile-form textarea { min-height: 100px; }.profile-form input:focus, .profile-form textarea:focus, .profile-form select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,148,29,.16); }
.profile-preferences { display: grid; gap: 14px; margin-top: 28px; padding-top: 25px; border-top: 1px solid var(--line); }.profile-preferences .eyebrow { margin: 0; }.profile-select-row { display: grid; gap: 8px; color: #f1e5dc; font-size: .85rem; font-weight: 800; }.profile-select-row select { width: 100%; padding: 12px 13px; border: 1px solid var(--line); border-radius: 12px; outline: none; color: var(--paper); background: var(--ink-deep); }.profile-select-row select:focus { border-color: var(--accent); box-shadow: 0 0 0 3px rgba(255,148,29,.16); }
.setting-row { display: flex !important; align-items: center; justify-content: space-between; gap: 18px !important; padding: 15px; border: 1px solid var(--line); border-radius: 14px; }.setting-row small { display: block; max-width: 470px; margin-top: 4px; color: var(--muted); font-weight: 400; line-height: 1.35; }.setting-switch { position: relative; width: 48px !important; height: 28px !important; margin: 0; flex: 0 0 auto; appearance: none; border: 0 !important; border-radius: 999px !important; outline: 0; background: #52728b !important; cursor: pointer; transition: background .2s ease; }.setting-switch::after { position: absolute; top: 4px; left: 4px; width: 20px; height: 20px; border-radius: 50%; background: #fff; content: ''; box-shadow: 0 2px 5px rgba(0,0,0,.25); transition: transform .2s ease; }.setting-switch:checked { background: var(--accent) !important; }.setting-switch:checked::after { transform: translateX(20px); }.setting-switch:focus-visible { box-shadow: 0 0 0 3px rgba(255,148,29,.28); }.setting-switch:disabled { opacity: .55; }
.avatar-crop-dialog { width: min(94vw, 660px); max-height: min(94dvh, 790px); padding: 0; overflow-y: auto; border: 1px solid rgba(255,255,255,.16); border-radius: 24px; color: var(--paper); background: var(--ink-soft); box-shadow: 0 28px 80px rgba(0,0,0,.48); }.avatar-crop-dialog::backdrop { background: rgba(0,0,0,.78); backdrop-filter: blur(6px); }.avatar-crop-panel { display: grid; gap: 18px; padding: clamp(18px, 4vw, 30px); }.avatar-crop-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; }.avatar-crop-heading h2 { margin: 3px 0 0; font-size: clamp(1.3rem, 3vw, 1.55rem); letter-spacing: -.025em; }.avatar-crop-heading .avatar-crop-close { width: 40px; height: 40px; padding: 0; flex: 0 0 auto; border: 1px solid var(--line); font-size: 1.65rem; line-height: 1; }.avatar-crop-help { max-width: 510px; margin: -7px 0 0; color: var(--muted); font-size: .9rem; line-height: 1.45; }.avatar-crop-stage { width: min(100%, 530px, max(220px, calc(94dvh - 345px))); aspect-ratio: 1; margin: 0 auto; overflow: hidden; border: 1px solid rgba(255,255,255,.12); border-radius: 18px; background: #080e16; box-shadow: inset 0 0 0 1px rgba(0,0,0,.25); }.avatar-crop-stage img { display: block; max-width: 100%; }.avatar-crop-stage .cropper-view-box { border: 0; border-radius: 0; outline: 0; }.avatar-crop-stage .cropper-face { background: transparent; }.avatar-crop-stage .cropper-line, .avatar-crop-stage .cropper-point { display: none; }.avatar-crop-tools { display: grid; grid-template-columns: auto minmax(180px, 1fr); align-items: center; gap: 18px; padding: 12px; border: 1px solid var(--line); border-radius: 15px; background: rgba(0,0,0,.15); }.avatar-crop-rotate { display: flex; align-items: center; gap: 7px; }.crop-tool-button { min-height: 38px; padding: 0 12px; border: 1px solid var(--line); border-radius: 10px; color: var(--paper); background: rgba(255,255,255,.05); font-size: .84rem; font-weight: 800; cursor: pointer; }.crop-tool-button:first-child, .crop-tool-button:last-child { width: 38px; padding: 0; font-size: 1.35rem; line-height: 1; }.crop-tool-button:hover { border-color: var(--accent); background: rgba(255,148,29,.14); }.crop-tool-button:focus-visible, .avatar-crop-zoom input:focus-visible { outline: 3px solid rgba(255,148,29,.3); outline-offset: 2px; }.avatar-crop-zoom { display: grid; grid-template-columns: 42px 1fr; align-items: center; gap: 10px; color: var(--muted); font-size: .78rem; font-weight: 800; }.avatar-crop-zoom input { width: 100%; accent-color: var(--accent); cursor: pointer; }.avatar-crop-actions { display: flex; justify-content: flex-end; gap: 10px; }.avatar-crop-actions button { min-width: 118px; }.avatar-crop-actions button:disabled { opacity: .6; cursor: wait; }
.primary-button, .secondary-button { min-height: 46px; padding: 0 18px; border-radius: 12px; font-weight: 900; }.primary-button { border: 0; color: var(--ink); background: var(--paper); }.primary-button:hover { background: #f0c39d; }.secondary-button { border: 1px solid var(--line); color: var(--paper); background: transparent; }.secondary-button:hover { background: rgba(255,255,255,.08); }.profile-bio { margin: 30px 0 18px; color: #e6d9d1; line-height: 1.55; }.profile-counts { display: flex; gap: 28px; color: var(--muted); }.profile-counts strong { display: block; color: var(--paper); font-size: 1.1rem; }.profile-actions { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; margin-top: 26px; }.relationship-label { display: inline-flex; padding: 10px 14px; border: 1px solid var(--line); border-radius: 12px; color: var(--muted); font-weight: 800; }
.danger-button { border-color: rgba(255,138,138,.65); color: #ffb4a8; }.danger-button:hover { background: rgba(255,138,138,.12); }.report-dialog { width: min(100% - 28px, 460px); border: 1px solid var(--line); border-radius: 20px; color: var(--paper); background: var(--ink-soft); box-shadow: var(--shadow); }.report-dialog::backdrop { background: rgba(0,0,0,.65); }.report-form { display: grid; gap: 16px; }.report-form h2 { margin: 0; }.report-form label { display: grid; gap: 7px; color: var(--muted); font-weight: 800; }.report-form select, .report-form textarea { width: 100%; padding: 11px 12px; border: 1px solid var(--line); border-radius: 10px; outline: none; color: var(--paper); background: var(--ink-deep); }.report-form textarea { min-height: 92px; resize: vertical; }.report-actions { display: flex; justify-content: flex-end; gap: 10px; }
.safety-center-link { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 15px; border: 1px solid rgba(255,148,29,.42); border-radius: 14px; color: var(--paper); background: rgba(255,148,29,.08); text-decoration: none; transition: .2s ease; }.safety-center-link:hover { border-color: var(--accent); background: rgba(255,148,29,.14); transform: translateY(-1px); }.safety-center-link strong, .safety-center-link small { display: block; }.safety-center-link small { max-width: 470px; margin-top: 4px; color: var(--muted); font-weight: 400; line-height: 1.35; }.safety-center-link b { color: var(--accent); font-size: 1.25rem; }

/* Safety Center */
.safety-page { min-height: 100dvh; background: radial-gradient(circle at 84% 0%, rgba(255,148,29,.18), transparent 28%), radial-gradient(circle at 8% 24%, rgba(20,137,203,.25), transparent 30%), var(--ink-deep); }.safety-shell { width: min(100% - 32px, 1040px); margin: 0 auto; padding: max(18px, env(safe-area-inset-top)) 0 max(38px, env(safe-area-inset-bottom)); }.safety-topbar { display: flex; align-items: center; justify-content: space-between; margin-bottom: clamp(28px, 6vw, 56px); }.safety-topbar .brand { font-size: 1.35rem; }.safety-hero { position: relative; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 20px; padding: clamp(24px, 5vw, 48px); border: 1px solid rgba(255,255,255,.14); border-radius: 30px; background: linear-gradient(135deg, rgba(12,92,145,.72), rgba(4,29,52,.92)); box-shadow: var(--shadow); overflow: hidden; }.safety-hero::after { position: absolute; right: -55px; bottom: -90px; width: 250px; height: 250px; border: 35px solid rgba(255,148,29,.12); border-radius: 50%; content: ''; }.safety-hero-icon, .safety-card-icon { display: grid; place-items: center; width: 58px; height: 58px; border-radius: 18px; color: var(--ink); background: var(--accent); box-shadow: 0 12px 28px rgba(255,148,29,.24); }.safety-hero-icon svg, .safety-card-icon svg, .safety-promise svg { width: 29px; height: 29px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }.safety-hero .eyebrow, .safety-section-heading .eyebrow { margin: 0; }.safety-hero h1 { position: relative; z-index: 1; margin: 4px 0 10px; font-size: clamp(2rem, 5vw, 3.4rem); letter-spacing: -.06em; }.safety-hero p:not(.eyebrow) { position: relative; z-index: 1; max-width: 700px; margin: 0; color: #e5eff6; font-size: clamp(1rem, 2vw, 1.12rem); line-height: 1.6; }.safety-hero small { grid-column: 2; position: relative; z-index: 1; color: var(--muted); font-size: .78rem; }.safety-promise { display: flex; gap: 13px; align-items: flex-start; margin: 18px 0 48px; padding: 16px 18px; border: 1px solid rgba(74,222,128,.28); border-radius: 16px; color: #dffbea; background: rgba(74,222,128,.08); }.safety-promise svg { width: 22px; height: 22px; flex: 0 0 auto; color: var(--green); }.safety-promise p { margin: 0; line-height: 1.5; }.safety-section { margin-top: 42px; }.safety-section-heading { margin-bottom: 18px; }.safety-section-heading h2 { margin: 4px 0 0; font-size: clamp(1.4rem, 3vw, 2rem); letter-spacing: -.04em; }.safety-section-heading > p:not(.eyebrow) { max-width: 650px; margin: 10px 0 0; color: var(--muted); line-height: 1.5; }.safety-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }.safety-card { display: flex; flex-direction: column; padding: 24px; border: 1px solid var(--line); border-radius: 22px; background: rgba(10,72,118,.65); }.safety-card-icon { width: 42px; height: 42px; margin-bottom: 22px; border-radius: 13px; color: var(--paper); background: var(--surface); box-shadow: none; }.safety-card-icon svg { width: 22px; height: 22px; }.safety-card .eyebrow { margin: 0; }.safety-card h3 { margin: 5px 0 9px; font-size: 1.16rem; letter-spacing: -.02em; }.safety-card-summary { margin: 0; color: #e6f0f7; line-height: 1.5; }.safety-card ul { display: grid; gap: 8px; margin: 18px 0 22px; padding: 0; list-style: none; color: var(--muted); font-size: .9rem; line-height: 1.45; }.safety-card li { position: relative; padding-left: 17px; }.safety-card li::before { position: absolute; top: .58em; left: 0; width: 6px; height: 6px; border-radius: 50%; background: var(--accent); content: ''; }.safety-card-link { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 16px; border-top: 1px solid rgba(255,255,255,.1); color: var(--paper); font-size: .9rem; font-weight: 800; text-decoration: none; }.safety-card-link:hover { color: var(--accent); }.safety-card-link span { font-size: 1.2rem; }.safety-roadmap { padding: clamp(22px, 5vw, 38px); border: 1px solid rgba(255,148,29,.28); border-radius: 26px; background: rgba(255,148,29,.06); }.safety-future-list { display: grid; gap: 12px; }.safety-future-list article { display: flex; gap: 12px; align-items: flex-start; padding: 15px; border-radius: 14px; background: rgba(0,0,0,.13); }.safety-future-list article > span { color: var(--accent); }.safety-future-list h3 { margin: 0 0 5px; font-size: 1rem; }.safety-future-list p { margin: 0; color: var(--muted); line-height: 1.5; }.safety-footer { display: flex; justify-content: space-between; gap: 20px; align-items: center; margin-top: 34px; padding: 22px 0 0; border-top: 1px solid rgba(255,255,255,.12); color: var(--muted); }.safety-footer p { max-width: 680px; margin: 0; line-height: 1.5; }.safety-footer a { color: var(--accent); font-weight: 800; text-decoration: none; white-space: nowrap; }

.chat-area { position: relative; flex: 1; min-width: 0; min-height: 0; display: flex; flex-direction: column; background: var(--ink-deep); }
.chat-header {
    z-index: 1; display: flex; align-items: center; gap: 13px; margin: 27px 28px 0; padding: 14px 18px;
    border: 1px solid var(--line); border-radius: 27px; background: var(--ink-soft); box-shadow: 0 8px 30px rgba(0,0,0,.08);
}
.recipient-profile-button {
    display: flex;
    min-width: 0;
    flex: 1;
    align-items: center;
    gap: 13px;
    padding: 0;
    border: 0;
    color: var(--paper);
    background: transparent;
    text-align: left;
    cursor: pointer;
}

.recipient-profile-button:disabled {
    cursor: default;
}

.recipient-avatar {
    width: 48px;
    height: 48px;
    flex: 0 0 auto;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface);
}

.recipient-details {
    display: grid;
    min-width: 0;
    gap: 3px;
}

.recipient-details strong {
    overflow: hidden;
    color: var(--paper);
    font-size: 1.12rem;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.recipient-details small {
    color: var(--green);
    font-size: .82rem;
}

.recipient-details small.offline {
    color: var(--muted);
}
.mobile-back { display: none; }
.empty-chat { display: grid; place-content: center; justify-items: center; flex: 1; gap: 9px; padding: 40px; text-align: center; color: var(--muted); }
.empty-chat-icon { display: grid; place-items: center; width: 62px; height: 62px; margin-bottom: 8px; border-radius: 22px; color: #f0c39d; background: var(--surface); font-size: 1.8rem; }
.empty-chat h2 { margin: 0; color: var(--paper); font-size: 1.2rem; }
.empty-chat p { max-width: 280px; margin: 0; font-size: .9rem; line-height: 1.5; }
.messages { flex: 1; min-height: 0; overflow-y: auto; padding: 28px 42px; scrollbar-color: var(--line) transparent; }
.messages[hidden], .empty-chat[hidden], .typing[hidden] { display: none !important; }
.message { position: relative; max-width: min(74%, 640px); width: fit-content; margin: 0 0 18px; padding: 13px 16px 9px; font-size: 1rem; line-height: 1.42; box-shadow: 0 4px 12px rgba(0,0,0,.05); }
.message.received { color: var(--paper); border: 1px solid #5a3c22; border-radius: 22px 22px 22px 7px; background: var(--surface); }
.message.sent { margin-left: auto; padding-right: 38px; color: var(--ink); border-radius: 22px 22px 7px 22px; background: var(--paper); }
.message.deleted { font-style: italic; opacity: .72; box-shadow: none; }
.message.deleted .message-content { color: inherit; }
.message-content { display: block; white-space: pre-wrap; overflow-wrap: anywhere; }
.message-meta { display: block; margin-top: 5px; color: inherit; font-size: .68rem; opacity: .58; text-align: right; }
.message-status { margin-left: 3px; font-weight: 800; letter-spacing: -2px; }
.message-status.seen { color: #438cd5; opacity: 1; }
.message-actions { position: absolute; top: 6px; right: 5px; z-index: 2; }
.message-options { display: grid; place-items: center; width: 25px; height: 25px; padding: 0; border: 0; border-radius: 50%; color: inherit; opacity: 0; background: transparent; font-size: 1.2rem; line-height: 1; cursor: pointer; transition: opacity .15s ease, background .15s ease; }
.message.sent:hover .message-options, .message-options:focus-visible, .message-options[aria-expanded="true"] { opacity: .72; }
.message-options:hover, .message-options:focus-visible, .message-options[aria-expanded="true"] { background: rgba(0,0,0,.1); opacity: 1; }
.message-options-menu { position: absolute; top: 29px; right: 0; min-width: 142px; padding: 5px; border: 1px solid var(--line); border-radius: 10px; background: var(--ink-soft); box-shadow: var(--shadow); }
.message-delete { width: 100%; padding: 8px 10px; border: 0; border-radius: 7px; color: #ffb4a8; background: transparent; font: inherit; font-size: .78rem; text-align: left; cursor: pointer; }
.message-delete:hover, .message-delete:focus-visible { color: #fff0ed; background: rgba(255,255,255,.1); }
@media (hover: none) { .message-options { opacity: .72; } }
.disappearing-request-card { display: grid; gap: 12px; max-width: min(100%, 520px); margin: 0 auto 20px; padding: 15px; border: 1px solid rgba(255,148,29,.42); border-radius: 16px; color: var(--paper); background: rgba(255,148,29,.1); text-align: center; }.disappearing-request-card p { margin: 0; font-size: .9rem; line-height: 1.45; }.disappearing-request-actions { display: flex; justify-content: center; gap: 10px; }.disappearing-request-actions .primary-button, .disappearing-request-actions .secondary-button { min-height: 38px; }.conversation-options-dialog { width: min(92vw, 470px); padding: 0; overflow: hidden; border: 1px solid var(--line); border-radius: 20px; color: var(--paper); background: var(--ink-soft); box-shadow: var(--shadow); }.conversation-options-dialog::backdrop { background: rgba(0,0,0,.7); backdrop-filter: blur(4px); }.conversation-options-panel { display: grid; gap: 17px; padding: 22px; }.conversation-options-heading { display: flex; align-items: start; justify-content: space-between; gap: 16px; }.conversation-options-heading h2 { margin: 3px 0 0; font-size: 1.3rem; }.conversation-options-heading .icon-button { width: 37px; height: 37px; border: 1px solid var(--line); font-size: 1.5rem; }.conversation-options-help { margin: -5px 0 0; color: var(--muted); font-size: .9rem; line-height: 1.45; }.conversation-options-panel fieldset { display: grid; gap: 8px; margin: 0; padding: 0; border: 0; }.disappearing-timer-option { display: flex; align-items: center; gap: 10px; padding: 13px; border: 1px solid var(--line); border-radius: 12px; cursor: pointer; }.disappearing-timer-option:has(input:checked) { border-color: var(--accent); background: rgba(255,148,29,.1); }.conversation-options-actions { display: flex; justify-content: flex-end; gap: 10px; }.conversation-options-panel fieldset:disabled { opacity: .55; }
.typing { display: flex; align-items: center; gap: 5px; margin: 0 42px 8px; color: var(--muted); font-size: .75rem; }
.typing span { width: 7px; height: 7px; border-radius: 50%; background: var(--muted); animation: typing-bounce 1.2s infinite ease-in-out; }
.typing span:nth-child(2) { animation-delay: .15s; }.typing span:nth-child(3) { animation-delay: .3s; }.typing small { margin-left: 3px; }
@keyframes typing-bounce { 0%,60%,100% { transform: translateY(0); opacity:.35; } 30% { transform: translateY(-4px); opacity:1; } }
.message-box { display: flex; align-items: center; gap: 8px; margin: 0 28px 28px; padding: 9px 11px; border: 1px solid var(--line); border-radius: 25px; background: var(--ink-soft); }
.message-box input { min-width: 0; flex: 1; height: 42px; padding: 0 8px; border: 0; outline: none; color: var(--paper); background: transparent; }
.message-box input::placeholder { color: var(--muted); }
.composer-action { width: 38px; height: 38px; }
.send-button { border: 0; color: var(--ink); background: var(--paper); }
.send-button:hover:not(:disabled) { transform: scale(1.04); background: #f0c39d; }
.toast-region { position: fixed; z-index: 20; right: 22px; bottom: 22px; display: grid; gap: 10px; width: min(360px, calc(100vw - 44px)); }
.toast { padding: 14px 16px; border: 1px solid rgba(255,255,255,.18); border-radius: 15px; color: var(--paper); background: #4b3021; box-shadow: var(--shadow); animation: toast-in .25s ease-out; }
.toast.error { border-color: rgba(255,138,138,.5); }.toast.success { border-color: rgba(74,222,128,.45); }
@keyframes toast-in { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
body.dashboard-page {
    height: 100dvh;
    overflow: hidden;
}

.dashboard-page .chat-app {
    height: 100dvh;
    min-height: 0;
    overflow: hidden;
}

.dashboard-page .sidebar,
.dashboard-page .chat-area {
    height: 100%;
    min-height: 0;
    overflow: hidden;
}

.dashboard-page .user-list,
.dashboard-page .messages {
    min-height: 0;
    overflow-y: auto;
    overscroll-behavior: contain;
}

.typing[hidden],
.messages[hidden],
.empty-chat[hidden] {
    display: none !important;
}

.recipient-details p.offline {
    color: var(--muted);
}

.logout-button:hover {
    color: #ffb4a8;
    background: rgba(255, 138, 138, .16);
}

.unread-badge {
    display: grid;
    min-width: 22px;
    height: 22px;
    padding: 0 6px;
    place-items: center;
    border-radius: 999px;
    color: var(--ink);
    background: var(--paper);
    font-size: .7rem;
    font-weight: 800;
}

.user-profile-trigger {
    display: grid;
    flex: 0 0 auto;
    width: 52px;
    height: 52px;
    padding: 0;
    overflow: hidden;
    border: 0;
    border-radius: 50%;
    background: transparent;
    cursor: pointer;
}

.user-profile-name {
    max-width: 100%;
    padding: 0;
    overflow: hidden;
    border: 0;
    color: inherit;
    background: transparent;
    font: inherit;
    font-size: .98rem;
    font-weight: 800;
    text-align: left;
    text-overflow: ellipsis;
    white-space: nowrap;
    cursor: pointer;
}

.user-profile-trigger:focus-visible,
.user-profile-name:focus-visible {
    outline: 2px solid #f0c39d;
    outline-offset: 3px;
}

.notification-item {
    grid-template-columns: 44px minmax(0, 1fr);
}

.notification-media {
    position: relative;
    width: 44px;
    height: 44px;
}

.notification-avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    object-fit: cover;
    background: var(--surface);
}

.notification-avatar-placeholder {
    display: block;
}

.notification-kind-icon {
    position: absolute;
    right: -3px;
    bottom: -3px;
    display: grid;
    width: 18px;
    height: 18px;
    place-items: center;
    border: 2px solid var(--ink-soft);
    border-radius: 50%;
    color: var(--ink);
    background: var(--paper);
    font-size: .62rem;
    font-weight: 900;
}

.notification-chat { border-left: 3px solid #6caef2; }
.notification-event { border-left: 3px solid #e8b27b; }
.notification-request { border-left-color: #c99aff; }
.notification-accepted { border-left-color: var(--green); }
.notification-rejected { border-left-color: #ff9b91; }

.notification-actions {
    grid-column: 2;
}

.blocked-accounts {
    display: grid;
    gap: 12px;
    margin-top: 28px;
    padding-top: 25px;
    border-top: 1px solid var(--line);
}

.blocked-accounts .eyebrow {
    margin: 0;
}

.blocked-account-row {
    display: grid;
    grid-template-columns: 42px minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    padding: 11px 0;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.blocked-account-row img {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    object-fit: cover;
}

.blocked-account-row span {
    min-width: 0;
}

.blocked-account-row strong,
.blocked-account-row small {
    display: block;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.blocked-account-row strong {
    color: var(--paper);
}

.blocked-account-row small {
    margin-top: 3px;
    color: var(--muted);
}

.device-sessions {
    display: grid;
    gap: 10px;
    margin-top: 28px;
    padding-top: 25px;
    border-top: 1px solid var(--line);
}

.section-heading {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 14px;
}

.section-heading h2 { margin: 3px 0 0; font-size: 1rem; }

.setting-help { margin: 0; color: var(--muted); font-size: .86rem; line-height: 1.5; }

.device-session-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 14px;
    padding: 11px 0;
    border-bottom: 1px solid rgba(255, 255, 255, .08);
}

.device-session-row strong, .device-session-row small { display: block; }
.device-session-row strong { color: var(--paper); }
.device-session-row small { margin-top: 3px; color: var(--muted); font-size: .78rem; }

.current-device-label {
    flex: 0 0 auto;
    padding: 4px 9px;
    border-radius: 999px;
    color: #092f2a;
    background: #7be1cf;
    font-size: .72rem;
    font-weight: 800;
}

.emoji-picker {
    position: absolute;
    right: 28px;
    bottom: 92px;
    z-index: 12;
    width: min(380px, calc(100vw - 56px));
    height: 440px;
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 18px;
    box-shadow: var(--shadow);
}

.emoji-picker[hidden] {
    display: none;
}

.notification-button,
.request-button {
    position: relative;
}

.request-decision-note {
    display: block;
    margin-top: 7px;
    color: var(--muted);
    font-size: .78rem;
    line-height: 1.4;
}