/* ============ CSS VARIABLES ============ */
:root {
    --navy: #1b3358;
    --navy-dark: #132544;
    --navy-light: #2a4a7f;
    --coral: #FF6B6B;
    --warm-pink: #FF8E8E;
    --soft-coral: #FFE5E5;
    --gold: #FFD93D;
    --teal: #4ECDC4;
    --slate: #6C7B95;
    --light-gray: #F4F6F8;
    --white: #FFFFFF;
    --error: #E74C3C;
    --success: #27ae60;
    --text-primary: #1b3358;
    --text-secondary: #6C7B95;
    --text-light: #999;
    --input-bg: #f0f2f5;
    --input-border: #ddd;
    --radius: 12px;
    --tab-height: 72px;
    --header-height: 56px;
}

/* ============ 1. RESET & BASE ============ */
*, *::before, *::after {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    width: 100%;
    height: 100%;
    margin: 0;
    padding: 0;
    overflow: hidden;
    overscroll-behavior: none;
}

body {
    font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background: var(--light-gray);
    color: var(--text-primary);
    -webkit-text-size-adjust: 100%;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    touch-action: pan-y;
}

#app {
    width: 100%;
    height: 100%;
    overflow-y: auto;
    overflow-x: hidden;
    position: relative;
    background: var(--light-gray);
    -webkit-overflow-scrolling: touch;
}

button { font-family: inherit; }
input, select, textarea { font-family: inherit; font-size: 16px; }
a { text-decoration: none; color: inherit; }

/* ============ GLOBAL HORIZONTAL LOCK ============ */
#app, .screen, .tab-content, .tab-pane {
    overflow-x: hidden;
}
img {
    max-width: 100%;
}
/* Admin breadcrumb */
.admin-breadcrumb {
    font-size: 11px;
    color: rgba(255,255,255,0.7);
    text-align: center;
    padding: 0;
    letter-spacing: 0.5px;
}

/* ============ 2. SCREEN SYSTEM ============ */
.screen { display: none; width: 100%; }
.screen.active { display: flex; flex-direction: column; width: 100%; min-height: 100%; }

/* ============ 3. WELCOME & LOGIN SCREENS ============ */
#screen-welcome {
    background: linear-gradient(135deg, #0f2027 0%, #1b3358 35%, #2a4a7f 65%, #1a3050 100%);
    min-height: 100vh;
    justify-content: center;
    align-items: center;
    padding: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
#screen-welcome::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 20% 50%, rgba(255,107,107,0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 20%, rgba(78,205,196,0.06) 0%, transparent 40%),
                radial-gradient(ellipse at 50% 100%, rgba(255,217,61,0.05) 0%, transparent 50%);
    pointer-events: none;
}

#screen-login {
    background: linear-gradient(135deg, #0f2027 0%, #1b3358 35%, #2a4a7f 65%, #1a3050 100%);
    min-height: 100vh;
    justify-content: center;
    align-items: center;
    padding: 30px;
    text-align: center;
    position: relative;
    overflow: hidden;
}
#screen-login::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 20% 50%, rgba(255,107,107,0.08) 0%, transparent 50%),
                radial-gradient(ellipse at 80% 20%, rgba(78,205,196,0.06) 0%, transparent 40%),
                radial-gradient(ellipse at 50% 100%, rgba(255,217,61,0.05) 0%, transparent 50%);
    pointer-events: none;
}
#screen-login::after {
    content: '';
    position: absolute;
    inset: 0;
    background: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='noise'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23noise)' opacity='0.03'/%3E%3C/svg%3E");
    opacity: 0.4;
    pointer-events: none;
}

.logo-icon {
    font-size: 80px;
    margin-bottom: 16px;
    filter: drop-shadow(0 0 24px rgba(255,107,107,0.3));
    animation: logoFloat 3s ease-in-out infinite;
    position: relative;
    z-index: 1;
}
@keyframes logoFloat {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-8px); }
}

.logo-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 36px;
    font-weight: 800;
    letter-spacing: -0.5px;
    margin-bottom: 4px;
    background: linear-gradient(135deg, #ffffff 0%, #FFE5E5 50%, #ffffff 100%);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    position: relative;
    z-index: 1;
}

.logo-subtitle {
    font-size: 15px;
    color: rgba(255,255,255,0.55);
    margin-bottom: 36px;
    font-weight: 300;
    letter-spacing: 1px;
    text-transform: uppercase;
    position: relative;
    z-index: 1;
}

.login-tagline {
    color: rgba(255,255,255,0.7);
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 44px;
    position: relative;
    z-index: 1;
}

.login-input {
    width: 100%;
    padding: 20px 24px;
    font-size: 20px;
    border: 1px solid rgba(255,255,255,0.15);
    border-radius: 16px;
    background: rgba(255,255,255,0.08);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    color: var(--white);
    text-align: center;
    letter-spacing: 2px;
    outline: none;
    transition: all 0.3s;
    position: relative;
    z-index: 1;
}
.login-input::placeholder { color: rgba(255,255,255,0.3); letter-spacing: 1px; }
.login-input:focus {
    background: rgba(255,255,255,0.15);
    border-color: rgba(255,107,107,0.5);
    box-shadow: 0 0 20px rgba(255,107,107,0.15);
}

.login-btn {
    width: 100%;
    padding: 18px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 100%);
    color: var(--white);
    cursor: pointer;
    margin-top: 20px;
    transition: all 0.25s;
    box-shadow: 0 8px 28px rgba(255,107,107,0.4);
    position: relative;
    z-index: 1;
    letter-spacing: 0.5px;
}
.login-btn:active { transform: scale(0.97); box-shadow: 0 4px 16px rgba(255,107,107,0.3); }
.login-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; box-shadow: none; }

.login-hint {
    color: rgba(255,255,255,0.35);
    font-size: 12px;
    margin-top: 20px;
    position: relative;
    z-index: 1;
    letter-spacing: 0.3px;
}

/* ============ 4. VERIFY SCREEN ============ */
#screen-verify {
    background: linear-gradient(135deg, #0f2027 0%, #1b3358 35%, #2a4a7f 65%, #1a3050 100%);
    min-height: 100vh;
    justify-content: center;
    align-items: center;
    padding: 30px;
    text-align: center;
    position: relative;
}
#screen-verify::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse at 50% 50%, rgba(255,107,107,0.06) 0%, transparent 60%);
    pointer-events: none;
}

#screen-register-phone,
#screen-set-password,
#screen-forgot-phone,
#screen-forgot-code,
#screen-forgot-password {
    background: linear-gradient(135deg, #0f2027 0%, #1b3358 35%, #2a4a7f 65%, #1a3050 100%);
    min-height: 100vh;
    justify-content: center;
    align-items: center;
    padding: 30px;
    text-align: center;
    position: relative;
}

.verify-icon { font-size: 48px; margin-bottom: 16px; }
.verify-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--white);
    margin-bottom: 8px;
}
.verify-subtitle {
    color: rgba(255,255,255,0.6);
    font-size: 14px;
    margin-bottom: 32px;
}
.verify-phone {
    color: var(--coral);
    font-weight: 600;
}

.code-inputs {
    display: flex;
    gap: 8px;
    justify-content: center;
    margin-bottom: 20px;
}
.code-digit {
    width: 48px;
    height: 56px;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    border: 2px solid rgba(255,255,255,0.2);
    border-radius: 10px;
    background: rgba(255,255,255,0.1);
    color: var(--white);
    outline: none;
    transition: border-color 0.2s, background 0.2s;
}
.code-digit:focus {
    border-color: var(--coral);
    background: rgba(255,255,255,0.2);
}

.verify-btn {
    width: 100%;
    padding: 18px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: var(--radius);
    background: var(--coral);
    color: var(--white);
    cursor: pointer;
    margin-top: 8px;
    transition: opacity 0.2s, transform 0.1s;
    box-shadow: 0 4px 16px rgba(255,107,107,0.3);
}
.verify-btn:active { opacity: 0.8; transform: scale(0.98); }
.verify-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

.change-number {
    color: rgba(255,255,255,0.5);
    font-size: 13px;
    cursor: pointer;
    margin-top: 12px;
    text-decoration: underline;
    background: none;
    border: none;
    transition: color 0.2s;
}
.change-number:hover { color: rgba(255,255,255,0.7); }

/* ============ 5. APP HEADER ============ */
.app-header {
    background: linear-gradient(135deg, #1b3358 0%, #243f6c 100%);
    height: var(--header-height);
    display: flex;
    align-items: center;
    justify-content: space-between;
    position: sticky;
    top: 0;
    z-index: 100;
    padding: 0 12px;
    box-shadow: 0 4px 20px rgba(0,0,0,0.2);
    border-bottom: 1px solid rgba(255,255,255,0.05);
    overflow: visible;
}

.app-header-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 20px;
    font-weight: 700;
    color: var(--white);
    letter-spacing: -0.3px;
}

.header-action {
    position: absolute;
    background: none;
    border: none;
    color: var(--white);
    cursor: pointer;
    padding: 8px;
    display: none;
    align-items: center;
    justify-content: center;
    transition: opacity 0.2s;
    -webkit-appearance: none;
    appearance: none;
}
.header-action:active { opacity: 0.6; }
.header-action-left { left: 12px; }
.header-action-right { right: 12px; }
.header-action svg { width: 24px; height: 24px; }

/* ============ 6. TAB BAR ============ */
.tab-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(19,37,68,0.92);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    height: var(--tab-height);
    display: flex;
    align-items: center;
    justify-content: space-around;
    z-index: 100;
    box-shadow: 0 -4px 24px rgba(0,0,0,0.25);
    border-top: 1px solid rgba(255,255,255,0.06);
    padding-bottom: env(safe-area-inset-bottom, 0);
}

.tab-bar-inner {
    display: flex;
    width: 100%;
    max-width: 480px;
    margin: 0 auto;
}

.tab-item {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 4px;
    padding: 8px 0;
    cursor: pointer;
    background: none;
    border: none;
    color: rgba(255,255,255,0.5);
    transition: color 0.2s;
    position: relative;
}
.tab-item svg {
    width: 28px;
    height: 28px;
    fill: currentColor;
}
.tab-item span {
    font-size: 11px;
    font-weight: 600;
    letter-spacing: 0.2px;
}
.tab-item.active {
    color: var(--coral);
}
.tab-item .tab-badge {
    position: absolute;
    top: 4px;
    right: calc(50% - 18px);
    background: var(--coral);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    min-width: 16px;
    height: 16px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 4px;
}
.tab-item.has-alert .tab-badge {
    animation: badge-pulse 0.8s ease-in-out infinite;
    box-shadow: 0 0 8px rgba(255,107,107,0.8);
}
@keyframes badge-pulse {
    0%, 100% { transform: scale(1); box-shadow: 0 0 8px rgba(255,107,107,0.8); }
    50% { transform: scale(1.4); box-shadow: 0 0 16px rgba(255,107,107,1); }
}
/* Flash the entire tab icon when badge is active */
.tab-item.has-alert svg {
    animation: icon-flash 0.8s ease-in-out infinite;
}
.tab-item.has-alert span {
    animation: text-flash 0.8s ease-in-out infinite;
    font-weight: 700;
}
@keyframes icon-flash {
    0%, 100% { color: var(--coral); filter: drop-shadow(0 0 4px rgba(255,0,0,0.5)); }
    50% { color: white; filter: drop-shadow(0 0 8px rgba(255,107,107,1)); }
}
@keyframes text-flash {
    0%, 100% { color: var(--coral); }
    50% { color: white; text-shadow: 0 0 8px rgba(255,107,107,1); }
}

/* ============ PLAYING NOW TAB ============ */
.playing-container { padding: 12px 16px; padding-bottom: 80px; }
.playing-location-warn {
    background: #FFF3CD; border: 1px solid #FFEAA7; border-radius: var(--radius);
    padding: 10px 14px; font-size: 13px; color: #856404; cursor: pointer;
    margin-bottom: 12px; text-align: center;
}
.playing-map-wrap {
    position: relative; border-radius: var(--radius); overflow: hidden;
    margin-bottom: 12px; background: var(--light-gray);
}
.playing-map-img {
    width: 100%; height: 180px; object-fit: cover; display: block;
}
.playing-map-overlay {
    position: absolute; bottom: 8px; right: 8px;
}
.playing-map-expand-btn {
    background: rgba(255,255,255,0.95); border: none; border-radius: 8px;
    padding: 6px 12px; font-size: 12px; font-weight: 600; color: var(--navy);
    cursor: pointer; box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}
.playing-view-toggle {
    display: flex; background: var(--light-gray); border-radius: var(--radius);
    padding: 3px; margin-bottom: 12px; gap: 3px;
}
.playing-toggle-btn {
    flex: 1; padding: 8px; border: none; border-radius: 10px;
    font-size: 13px; font-weight: 600; cursor: pointer;
    background: transparent; color: var(--slate); transition: all 0.2s;
}
.playing-toggle-btn.active {
    background: white; color: var(--teal);
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}

.court-card {
    background: white; border-radius: var(--radius); margin-bottom: 10px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06); overflow: hidden;
}
.court-card-map { width: 100%; height: 120px; object-fit: cover; display: block; }
.court-card-body { padding: 12px 14px; }
.court-card-name { font-weight: 600; font-size: 14px; margin-bottom: 2px; }
.court-card-addr { font-size: 12px; color: var(--slate); margin-bottom: 6px; }
.court-card-dist { font-size: 12px; color: var(--teal); font-weight: 600; }
.court-card-actions { display: flex; gap: 8px; margin-top: 8px; }
.court-card-actions button {
    flex: 1; padding: 8px; border-radius: 8px; border: none;
    font-size: 12px; font-weight: 600; cursor: pointer;
}
.court-dir-btn { background: var(--light-gray); color: var(--navy); }
.court-beacon-btn { background: var(--teal); color: white; }

.playing-past-toggle {
    width: 100%; padding: 10px; border: 1px solid #eee; border-radius: var(--radius);
    background: white; cursor: pointer; display: flex; justify-content: space-between;
    align-items: center; font-size: 13px; font-weight: 600; color: var(--slate);
}
.past-beacon-card {
    background: white; border-radius: var(--radius); padding: 12px 14px;
    margin-top: 8px; opacity: 0.65; box-shadow: 0 1px 4px rgba(0,0,0,0.04);
}
.past-beacon-card .beacon-card-time { color: var(--slate); }

/* Full map overlay */
.fullmap-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: white; z-index: 250;
}
.fullmap-header {
    position: absolute; top: 0; left: 0; right: 0; height: 56px;
    background: var(--navy); display: flex; align-items: center; padding: 0 16px; z-index: 2;
}
.fullmap-back {
    background: none; border: none; color: white; font-size: 24px; cursor: pointer;
    margin-right: 12px;
}
.fullmap-title { color: white; font-weight: 600; font-size: 16px; flex: 1; }
.fullmap-img {
    width: 100%; height: calc(100% - 56px); margin-top: 56px; object-fit: cover;
}
.fullmap-legend {
    position: absolute; bottom: 20px; left: 16px; right: 16px;
    background: rgba(255,255,255,0.95); border-radius: var(--radius);
    padding: 12px; box-shadow: 0 4px 16px rgba(0,0,0,0.15);
}
.fullmap-legend-row { display: flex; align-items: center; gap: 8px; margin-bottom: 4px; font-size: 12px; }
.fullmap-dot { width: 12px; height: 12px; border-radius: 50%; }
.fullmap-dot-active { background: #E53E3E; }
.fullmap-dot-court { background: #4ECDC4; }

.beacon-card-map {
    width: 100%; height: 120px; object-fit: cover; border-radius: 8px;
    margin-bottom: 8px; display: block; background: var(--light-gray);
}
.beacon-card-bottom-actions {
    display: flex; gap: 8px; margin-top: 8px; padding-top: 8px;
    border-top: 1px solid #f0f0f0;
}
.beacon-chat-btn {
    flex: 1; display: flex; align-items: center; justify-content: center;
    gap: 6px; padding: 12px 14px; border-radius: 10px; border: none;
    background: linear-gradient(135deg, var(--teal), #38b2ac);
    color: white; font-size: 15px; font-weight: 700; cursor: pointer;
    box-shadow: 0 2px 8px rgba(78,205,196,0.3);
    touch-action: manipulation; -webkit-tap-highlight-color: rgba(78,205,196,0.3);
    min-height: 44px; position: relative; z-index: 2;
}
.beacon-directions-btn {
    display: inline-flex; align-items: center; justify-content: center;
    gap: 4px; padding: 12px 14px;
    border-radius: 10px; border: 1px solid var(--teal); background: white;
    color: var(--teal); font-size: 13px; font-weight: 600; cursor: pointer;
    touch-action: manipulation; -webkit-tap-highlight-color: rgba(78,205,196,0.3);
    min-height: 44px;
}

/* ---- Active Beacon Alert Pulse ---- */
@keyframes beaconPulse {
    0% { transform: scale(1); opacity: 1; }
    50% { transform: scale(1.3); opacity: 0.7; }
    100% { transform: scale(1); opacity: 1; }
}
@keyframes beaconGlow {
    0%, 100% { box-shadow: 0 0 4px rgba(255,60,60,0.4); }
    50% { box-shadow: 0 0 18px rgba(255,60,60,0.9), 0 0 36px rgba(255,60,60,0.4); }
}
@keyframes beaconFlash {
    0%, 100% { opacity: 1; background: linear-gradient(135deg, #FF4444, #FF6B6B); }
    50% { opacity: 0.85; background: linear-gradient(135deg, #FF6B6B, #FFD93D); }
}
@keyframes beaconBannerSlide {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
.tab-beacon-alert {
    position: absolute; top: 2px; right: calc(50% - 20px);
    width: 12px; height: 12px; border-radius: 50%;
    background: #FF4444; border: 2px solid rgba(19,37,68,0.92);
    animation: beaconPulse 1s ease-in-out infinite, beaconGlow 1s ease-in-out infinite;
}
@keyframes tabBeaconFlash {
    0%, 100% { color: #FF4444; transform: scale(1); filter: drop-shadow(0 0 4px rgba(255,68,68,0.6)); }
    50% { color: #FFFFFF; transform: scale(1.15); filter: drop-shadow(0 0 10px rgba(255,68,68,1)); }
}
.tab-item.beacon-active {
    animation: tabBeaconFlash 0.6s ease-in-out infinite !important;
    position: relative;
}
.tab-item.beacon-active span {
    color: #FF4444;
    font-weight: 700;
}
/* Beacon intro text */
.playing-intro {
    margin: 0 16px 12px;
    padding: 16px 18px;
    background: linear-gradient(135deg, #e8f4f8, #f0f7ff);
    border-radius: 14px;
    border-left: 4px solid var(--teal);
}
.playing-intro-title {
    font-size: 15px;
    font-weight: 800;
    color: var(--navy);
    margin-bottom: 6px;
}
.playing-intro-text {
    font-size: 13px;
    color: var(--slate);
    line-height: 1.55;
}

.playing-live-banner {
    border-radius: var(--radius); padding: 14px 16px;
    cursor: pointer; text-align: center;
    background: linear-gradient(270deg, #FF4444, #FF6B6B, #FFD93D, #FF6B6B, #FF4444);
    background-size: 400% 400%;
    animation: beaconBannerSlide 3s ease infinite, beaconFlash 2s ease-in-out infinite;
    color: white; font-weight: 700; font-size: 15px;
    box-shadow: 0 4px 20px rgba(255,68,68,0.4);
    position: relative; overflow: hidden;
    /* hidden by default — animations always run, just invisible */
    max-height: 0; opacity: 0; padding: 0 16px;
    margin-bottom: 0; pointer-events: none;
    transition: max-height 0.3s, opacity 0.3s, padding 0.3s, margin-bottom 0.3s;
}
.playing-live-banner.visible {
    max-height: 200px; opacity: 1; padding: 14px 16px;
    margin-bottom: 14px; pointer-events: auto;
}
.playing-live-banner::before {
    content: ''; position: absolute; top: -50%; left: -50%;
    width: 200%; height: 200%;
    background: radial-gradient(circle, rgba(255,255,255,0.2) 0%, transparent 60%);
    animation: beaconPulse 2s ease-in-out infinite;
}
.playing-live-banner .live-dot {
    display: inline-block; width: 10px; height: 10px; border-radius: 50%;
    background: white; margin-right: 8px;
    animation: beaconPulse 0.8s ease-in-out infinite;
}
.playing-live-count {
    font-size: 24px; font-weight: 800; display: block; margin: 4px 0;
}
.playing-live-sub {
    font-size: 12px; font-weight: 500; opacity: 0.9;
}
.playing-my-beacon {
    background: linear-gradient(135deg, var(--teal), #38b2ac);
    border-radius: var(--radius);
    padding: 16px;
    margin-bottom: 16px;
    color: white;
}
.playing-my-beacon h3 { font-size: 16px; margin-bottom: 8px; }
.playing-my-beacon .beacon-court { font-size: 14px; opacity: 0.9; margin-bottom: 4px; }
.playing-my-beacon .beacon-timer { font-size: 13px; opacity: 0.8; margin-bottom: 12px; }
.playing-my-beacon .beacon-stats { display: flex; gap: 16px; margin-bottom: 12px; }
.playing-my-beacon .beacon-stat { font-size: 13px; }
.playing-my-beacon .beacon-actions { display: flex; gap: 8px; }
.playing-my-beacon .beacon-actions button {
    flex: 1; padding: 8px; border-radius: 8px; border: none;
    font-size: 13px; font-weight: 600; cursor: pointer;
}
.beacon-btn-extend { background: rgba(255,255,255,0.25); color: white; }
.beacon-btn-cancel { background: rgba(255,255,255,0.15); color: rgba(255,255,255,0.8); }
.beacon-btn-chat { background: white; color: var(--teal); }

.beacon-card {
    background: white;
    border-radius: var(--radius);
    padding: 14px;
    margin-bottom: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.beacon-card-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.beacon-card-avatar {
    width: 42px; height: 42px; border-radius: 50%;
    object-fit: cover; background: var(--light-gray);
}
.beacon-card-info { flex: 1; }
.beacon-card-name { font-weight: 600; font-size: 14px; }
.beacon-card-skill { font-size: 12px; color: var(--slate); }
.beacon-card-time { font-size: 11px; color: var(--teal); font-weight: 600; }
.beacon-card-court { display: flex; align-items: center; gap: 8px; margin-bottom: 8px; }
.beacon-card-court-icon { color: var(--teal); font-size: 16px; }
.beacon-card-court-name { font-size: 13px; font-weight: 500; }
.beacon-card-court-dist { font-size: 12px; color: var(--slate); }
.beacon-card-message {
    background: var(--light-gray); border-radius: 8px;
    padding: 8px 10px; font-size: 13px; color: var(--text-secondary);
    margin-bottom: 10px; font-style: italic;
}
.beacon-card-footer { display: flex; align-items: center; gap: 8px; }
.beacon-card-responses { font-size: 12px; color: var(--slate); flex: 1; }
.beacon-card-btn {
    padding: 6px 14px; border-radius: 20px; border: none;
    font-size: 12px; font-weight: 600; cursor: pointer;
}
.beacon-btn-omw { background: var(--teal); color: white; }
.beacon-btn-interested { background: var(--soft-coral); color: var(--coral); }
.beacon-btn-responded { background: var(--light-gray); color: var(--slate); }

.playing-create-btn {
    position: fixed;
    bottom: calc(var(--tab-height) + 20px + env(safe-area-inset-bottom, 0px));
    right: max(16px, calc(50% - 224px));
    width: 56px; height: 56px; border-radius: 28px;
    background: linear-gradient(135deg, var(--teal), #38b2ac);
    border: none; color: white; font-size: 28px;
    box-shadow: 0 4px 16px rgba(78,205,196,0.4);
    cursor: pointer; z-index: 90;
    display: flex; align-items: center; justify-content: center;
}

.beacon-detail-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5); z-index: 200;
    display: flex; align-items: flex-end; justify-content: center;
}
.beacon-detail-sheet {
    background: white; border-radius: 20px 20px 0 0;
    width: 100%; max-width: 480px; max-height: 85vh;
    overflow-y: auto; padding: 20px 16px calc(20px + env(safe-area-inset-bottom, 0px));
}
.beacon-detail-header { display: flex; align-items: center; gap: 10px; margin-bottom: 16px; }
.beacon-detail-close {
    width: 32px; height: 32px; border-radius: 16px; border: none;
    background: var(--light-gray); font-size: 18px; cursor: pointer;
}
.beacon-detail-title { flex: 1; font-weight: 700; font-size: 16px; }

.beacon-detail-map {
    width: 100%; height: 160px; border-radius: var(--radius);
    object-fit: cover; background: var(--light-gray); margin-bottom: 12px;
}
.beacon-responders { margin-bottom: 12px; }
.beacon-responders h4 { font-size: 13px; color: var(--slate); margin-bottom: 8px; text-transform: uppercase; letter-spacing: 0.5px; }
.beacon-responder-row {
    display: flex; align-items: center; gap: 10px; padding: 6px 0;
}
.beacon-responder-avatar { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.beacon-responder-name { flex: 1; font-size: 13px; font-weight: 500; }
.beacon-responder-type { font-size: 11px; padding: 3px 8px; border-radius: 10px; }
.beacon-responder-omw { background: #e6faf8; color: var(--teal); }
.beacon-responder-interested { background: var(--soft-coral); color: var(--coral); }

.beacon-chat-area {
    border-top: 2px solid var(--teal); padding-top: 14px; margin-top: 12px;
    background: linear-gradient(to bottom, rgba(78,205,196,0.05), transparent);
    border-radius: 0 0 var(--radius) var(--radius);
    padding: 14px 4px 4px;
}
.beacon-chat-area h4 {
    display: flex; align-items: center; gap: 6px;
}
.beacon-chat-label {
    background: var(--teal); color: white; font-size: 10px; font-weight: 700;
    padding: 2px 8px; border-radius: 10px; text-transform: uppercase;
}
.beacon-chat-messages {
    max-height: 200px; overflow-y: auto; margin-bottom: 10px;
}
.beacon-chat-msg { display: flex; gap: 10px; margin-bottom: 10px; }
.beacon-chat-msg-avatar {
    width: 34px; height: 34px; border-radius: 50%; object-fit: cover;
    flex-shrink: 0; border: 2px solid var(--light-gray);
}
.beacon-chat-msg-body { flex: 1; }
.beacon-chat-msg-name { font-size: 12px; font-weight: 700; color: var(--text-primary); }
.beacon-chat-msg-body {
    background: var(--light-gray); border-radius: 0 12px 12px 12px;
    padding: 8px 12px; flex: 1;
}
.beacon-chat-msg-text { font-size: 13px; color: var(--text-primary); }
.beacon-chat-msg-time { font-size: 10px; color: var(--text-light); }
.beacon-chat-input {
    display: flex; gap: 8px;
}
.beacon-chat-input input {
    flex: 1; padding: 10px 14px; border-radius: 20px;
    border: 1px solid #ddd; font-size: 14px; outline: none;
}
.beacon-chat-input button {
    padding: 10px 16px; border-radius: 20px; border: none;
    background: var(--teal); color: white; font-weight: 600;
    font-size: 14px; cursor: pointer;
}

/* Create beacon flow */
.create-beacon-overlay {
    position: fixed; top: 0; left: 0; right: 0; bottom: 0;
    background: rgba(0,0,0,0.5); z-index: 200;
    display: flex; align-items: flex-end; justify-content: center;
}
.create-beacon-sheet {
    background: white; border-radius: 20px 20px 0 0;
    width: 100%; max-width: 480px; max-height: 85vh;
    overflow-y: auto; padding: 20px 16px calc(20px + env(safe-area-inset-bottom, 0px));
}
.create-beacon-sheet h3 {
    font-size: 18px; font-weight: 700; margin-bottom: 16px;
    display: flex; align-items: center; gap: 8px;
}
.court-search-wrap {
    position: relative; margin-bottom: 12px;
}
.court-search-input {
    width: 100%; padding: 12px 14px; border-radius: var(--radius);
    border: 1px solid #ddd; font-size: 14px; outline: none;
}
.court-search-results {
    position: absolute; top: 100%; left: 0; right: 0;
    background: white; border-radius: 0 0 var(--radius) var(--radius);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12); max-height: 200px;
    overflow-y: auto; z-index: 10; display: none;
}
.court-search-results.visible { display: block; }
.court-search-item {
    padding: 10px 14px; cursor: pointer; border-bottom: 1px solid #f0f0f0;
    font-size: 13px;
}
.court-search-item:hover { background: var(--light-gray); }
.court-search-item .court-item-name { font-weight: 600; }
.court-search-item .court-item-loc { color: var(--slate); font-size: 12px; }
.court-selected-card {
    background: var(--light-gray); border-radius: var(--radius);
    padding: 12px; margin-bottom: 12px; display: flex; align-items: center; gap: 10px;
}
.court-selected-name { font-weight: 600; font-size: 14px; flex: 1; }
.court-selected-remove {
    width: 24px; height: 24px; border-radius: 12px; border: none;
    background: rgba(0,0,0,0.1); cursor: pointer; font-size: 14px;
}
.create-beacon-field { margin-bottom: 14px; }
.create-beacon-field label { display: block; font-size: 13px; font-weight: 600; color: var(--slate); margin-bottom: 6px; }
.create-beacon-field select, .create-beacon-field input, .create-beacon-field textarea {
    width: 100%; padding: 10px 12px; border-radius: var(--radius);
    border: 1px solid #ddd; font-size: 14px; outline: none;
}
.create-beacon-field textarea { resize: none; height: 60px; }
.create-beacon-submit {
    width: 100%; padding: 14px; border-radius: var(--radius); border: none;
    background: linear-gradient(135deg, var(--teal), #38b2ac);
    color: white; font-size: 16px; font-weight: 700; cursor: pointer;
    margin-top: 8px;
}
.create-beacon-submit:disabled { opacity: 0.5; cursor: not-allowed; }

.playing-empty {
    text-align: center; padding: 60px 20px; color: var(--slate);
}
.playing-empty-icon { font-size: 48px; margin-bottom: 12px; }
.playing-empty-title { font-size: 18px; font-weight: 600; margin-bottom: 8px; color: var(--text-primary); }
.playing-empty-sub { font-size: 14px; line-height: 1.5; }

/* ============ 7. MAIN CONTENT ============ */
.tab-content {
    padding-top: var(--header-height);
    padding-bottom: calc(var(--tab-height) + env(safe-area-inset-bottom, 0px) + 16px);
    min-height: 100%;
    background: var(--light-gray);
}

.tab-pane { display: none; overflow-x: hidden; }
.tab-pane.active { display: block; overflow-x: hidden; }

/* ============ 8. DISCOVER CARD ============ */
.discover-container {
    padding: 8px 12px;
    position: relative;
}

.discover-card {
    width: 100%;
    height: calc(100vh - var(--header-height) - var(--tab-height) - 100px);
    max-height: 520px;
    border-radius: 20px;
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center center;
    background-color: var(--navy);
    box-shadow: 0 12px 48px rgba(0,0,0,0.2), 0 4px 12px rgba(0,0,0,0.1);
    cursor: grab;
    user-select: none;
    transition: transform 0.4s ease, opacity 0.4s ease;
}
@media (min-width: 600px) {
    .discover-card {
        max-width: 400px;
        margin: 0 auto;
    }
}
.discover-card:active { cursor: grabbing; }

.discover-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 80px 24px 24px;
    background: linear-gradient(to top, rgba(0,0,0,0.85) 0%, rgba(0,0,0,0.4) 45%, transparent 100%);
    pointer-events: none;
}

.discover-card-name {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 28px;
    font-weight: 700;
    color: var(--white);
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
}
.discover-card-name span {
    font-weight: 300;
    font-size: 22px;
    margin-left: 4px;
}

.discover-card-city {
    font-size: 14px;
    color: rgba(255,255,255,0.85);
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.discover-card-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 10px;
}
.discover-card-tag {
    padding: 4px 10px;
    font-size: 12px;
    font-weight: 500;
    background: rgba(255,255,255,0.2);
    color: var(--white);
    border-radius: 12px;
    backdrop-filter: blur(4px);
}

/* Swipe feedback stamps */
.discover-card-stamp {
    position: absolute;
    top: 40px;
    padding: 8px 20px;
    font-size: 32px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    border: 4px solid;
    border-radius: 12px;
    opacity: 0;
    transform: rotate(-15deg);
    transition: opacity 0.15s;
    pointer-events: none;
}
.discover-card-stamp.like {
    right: 20px;
    color: var(--success);
    border-color: var(--success);
    transform: rotate(15deg);
}
.discover-card-stamp.nope {
    left: 20px;
    color: var(--error);
    border-color: var(--error);
    transform: rotate(-15deg);
}

/* Swipe animations */
.discover-card.swipe-left {
    transform: translateX(-150%) rotate(-30deg);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s ease;
}
.discover-card.swipe-right {
    transform: translateX(150%) rotate(30deg);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s ease;
}
.discover-card.swipe-up {
    transform: translateY(-150%) scale(0.8);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s ease;
}

/* Photo dots on discover card */
.discover-photo-dots {
    position: absolute;
    top: 10px;
    left: 12px;
    right: 12px;
    display: flex;
    gap: 4px;
}
.discover-photo-dot {
    flex: 1;
    height: 3px;
    border-radius: 2px;
    background: rgba(255,255,255,0.4);
    transition: background 0.2s;
}
.discover-photo-dot.active { background: var(--white); }

/* Discover tap zones & controls */
.discover-tap-left, .discover-tap-right {
    position: absolute;
    top: 0;
    bottom: 40%;
    width: 50%;
    z-index: 5;
    cursor: pointer;
}
.discover-tap-left { left: 0; }
.discover-tap-right { right: 0; }
.discover-photo-counter {
    position: absolute;
    top: 20px;
    right: 12px;
    background: rgba(0,0,0,0.5);
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    z-index: 6;
    display: none;
}
.discover-info-btn {
    position: absolute;
    bottom: 80px;
    right: 16px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: none;
    background: rgba(0,0,0,0.35);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 6;
    transition: background 0.2s;
}
.discover-info-btn:active { background: rgba(0,0,0,0.6); }

/* Modal photo browsing */
.modal-photo-wrap {
    position: relative;
    width: 100%;
}
.modal-photo-left, .modal-photo-right {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 50%;
    z-index: 5;
    cursor: pointer;
}
.modal-photo-left { left: 0; }
.modal-photo-right { right: 0; }
.modal-photo-counter {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0,0,0,0.5);
    color: white;
    font-size: 12px;
    font-weight: 600;
    padding: 3px 10px;
    border-radius: 12px;
    z-index: 6;
    display: none;
}
.modal-photo-dots {
    position: absolute;
    bottom: 12px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 5px;
    z-index: 6;
}
.modal-photo-dot {
    width: 8px;
    height: 8px;
    border-radius: 4px;
    background: rgba(255,255,255,0.5);
    cursor: pointer;
    transition: all 0.2s;
}
.modal-photo-dot.active {
    background: white;
    width: 20px;
}
.modal-arrow-left, .modal-arrow-right {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0,0,0,0.35);
    color: white;
    font-size: 22px;
    display: none;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    z-index: 6;
    line-height: 1;
}
.modal-arrow-left { left: 8px; }
.modal-arrow-right { right: 8px; }

/* ============ 9. ACTION BUTTONS ============ */
.action-buttons {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 16px;
    padding: 12px 0 4px;
}

.action-btn {
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}
.action-btn:active { transform: scale(0.85); }
.action-btn svg { pointer-events: none; }

.btn-pass, .action-btn-pass {
    width: 58px;
    height: 58px;
    background: var(--white);
    border: 2px solid #e8e8e8;
    box-shadow: 0 4px 20px rgba(0,0,0,0.08), 0 1px 3px rgba(0,0,0,0.06);
}
.btn-pass svg, .action-btn-pass svg { width: 24px; height: 24px; color: var(--slate); }
.btn-pass:active, .action-btn-pass:active { box-shadow: 0 2px 8px rgba(0,0,0,0.1); }

.btn-superlike, .action-btn-superlike {
    width: 50px;
    height: 50px;
    background: linear-gradient(135deg, #FFD93D 0%, #FFE580 100%);
    border: none;
    box-shadow: 0 6px 20px rgba(255,217,61,0.4);
}
.btn-superlike svg, .action-btn-superlike svg { width: 22px; height: 22px; color: #8B6914; }

.btn-like, .action-btn-like {
    width: 64px;
    height: 64px;
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 100%);
    border: none;
    box-shadow: 0 8px 28px rgba(255,107,107,0.45);
}
.btn-like svg, .action-btn-like svg { width: 28px; height: 28px; color: var(--white); }

.action-btn-rewind {
    width: 44px;
    height: 44px;
    background: var(--white);
    border: 2px solid #e0e0e0;
}
.action-btn-rewind svg { width: 20px; height: 20px; color: var(--gold); }

.action-btn-boost {
    width: 44px;
    height: 44px;
    background: var(--white);
    border: 2px solid #e0e0e0;
}
.action-btn-boost svg { width: 20px; height: 20px; color: var(--teal); }

.btn-backtrack {
    width: 44px;
    height: 44px;
    background: var(--white);
    border: 2px solid #e0e0e0;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}
.btn-backtrack svg { width: 20px; height: 20px; color: var(--gold); }

.btn-boost {
    width: 44px;
    height: 44px;
    background: linear-gradient(135deg, #4ECDC4 0%, #6EE7DE 100%);
    border: none;
    box-shadow: 0 4px 14px rgba(78,205,196,0.35);
}
.btn-boost svg { width: 20px; height: 20px; color: var(--white); }

.people-count {
    text-align: center;
    padding: 10px 16px 2px;
    font-size: 13px;
    font-weight: 600;
    color: var(--slate);
    letter-spacing: 0.3px;
}

/* ============ 10. PROFILE GRID (Matches/Likes) ============ */
.profile-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
    padding: 16px;
    max-width: 1200px;
    margin: 0 auto;
}
@media (min-width: 500px) {
    .profile-grid { grid-template-columns: repeat(3, 1fr); gap: 14px; }
}
@media (min-width: 768px) {
    .profile-grid { grid-template-columns: repeat(4, 1fr); gap: 16px; }
}
@media (min-width: 1024px) {
    .profile-grid { grid-template-columns: repeat(5, 1fr); gap: 16px; }
}
@media (min-width: 1400px) {
    .profile-grid { grid-template-columns: repeat(6, 1fr); gap: 18px; }
}

.profile-grid-card {
    aspect-ratio: 4/5;
    border-radius: var(--radius);
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
    background-color: var(--navy);
    cursor: pointer;
    box-shadow: 0 2px 12px rgba(0,0,0,0.1);
    transition: transform 0.2s;
}
.profile-grid-card:active { transform: scale(0.97); }

.profile-grid-card-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 32px 12px 12px;
    background: linear-gradient(to top, rgba(0,0,0,0.65) 0%, transparent 100%);
}

.profile-grid-card-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--white);
}
.profile-grid-card-name span {
    font-weight: 300;
    font-size: 14px;
}

.profile-grid-card-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    background: var(--coral);
    color: var(--white);
    font-size: 10px;
    font-weight: 700;
    padding: 4px 8px;
    border-radius: 8px;
    text-transform: uppercase;
}

/* ============ 11. CHAT LIST ============ */
.chat-list {
    list-style: none;
}

.chat-list-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--white);
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
}
.chat-list-item:active { background: var(--light-gray); }

.chat-list-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
    background: var(--input-bg);
}

.chat-list-text {
    flex: 1;
    min-width: 0;
}

.chat-list-name {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}

.chat-list-preview {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.chat-list-preview.unread {
    color: var(--text-primary);
    font-weight: 600;
}

.chat-list-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}

.chat-list-time {
    font-size: 11px;
    color: var(--text-light);
}

.chat-list-badge {
    background: var(--coral);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
}

/* ============ 12. NEW MATCHES ROW ============ */
.new-matches {
    display: flex;
    gap: 16px;
    padding: 16px;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
}
.new-matches::-webkit-scrollbar { display: none; }

.new-match-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    cursor: pointer;
}

.new-match-avatar {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    border: 3px solid var(--coral);
    padding: 2px;
    object-fit: cover;
    background: var(--input-bg);
    box-shadow: 0 2px 8px rgba(255,107,107,0.2);
}

.new-match-name {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-primary);
    max-width: 68px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.new-matches-label {
    font-size: 13px;
    font-weight: 700;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 16px 16px 0;
}

/* ============ 13. CHAT VIEW ============ */
.chat-view {
    display: flex;
    flex-direction: column;
    height: 100vh;
    background: var(--light-gray);
}

.chat-header {
    background: var(--navy);
    height: var(--header-height);
    display: flex;
    align-items: center;
    padding: 0 12px;
    gap: 12px;
    position: sticky;
    top: 0;
    z-index: 100;
    box-shadow: 0 2px 8px rgba(0,0,0,0.15);
}

.chat-header-back {
    background: none;
    border: none;
    color: var(--white);
    cursor: pointer;
    padding: 8px;
    display: flex;
}
.chat-header-back svg { width: 24px; height: 24px; }

.chat-header-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    object-fit: cover;
}

.chat-header-name {
    color: var(--white);
    font-size: 16px;
    font-weight: 700;
    flex: 1;
}

.chat-messages {
    flex: 1;
    overflow-y: auto;
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.chat-message-row {
    display: flex;
    align-items: flex-end;
    gap: 8px;
    max-width: 85%;
}
.chat-message-row.sent {
    align-self: flex-end;
    flex-direction: row-reverse;
}
.chat-message-row.received {
    align-self: flex-start;
}
.chat-message-avatar {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}
.chat-message {
    max-width: 100%;
    padding: 12px 16px;
    border-radius: 18px;
    font-size: 15px;
    line-height: 1.4;
    word-wrap: break-word;
}

.chat-message.sent {
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 100%);
    color: var(--white);
    border-bottom-right-radius: 6px;
    box-shadow: 0 4px 16px rgba(255,107,107,0.25);
}

.chat-message.received {
    background: var(--white);
    color: var(--text-primary);
    border-bottom-left-radius: 6px;
    box-shadow: 0 1px 4px rgba(0,0,0,0.06);
}

.chat-message-time {
    font-size: 10px;
    color: var(--text-light);
    margin-top: 4px;
    white-space: nowrap;
}
.chat-message.sent .chat-message-time { color: rgba(255,255,255,0.7); text-align: right; }

.chat-date-divider {
    text-align: center;
    font-size: 12px;
    color: var(--text-light);
    margin: 12px 0;
    font-weight: 500;
}

.chat-input-bar {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    background: var(--white);
    border-top: 1px solid #eee;
    position: sticky;
    bottom: 0;
}

.chat-input {
    flex: 1;
    padding: 12px 16px;
    font-size: 15px;
    border: none;
    border-radius: 24px;
    background: var(--input-bg);
    color: var(--text-primary);
    outline: none;
}
.chat-input::placeholder { color: var(--text-light); }

.chat-send-btn {
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--coral);
    border: none;
    color: var(--white);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: opacity 0.2s, transform 0.1s;
}
.chat-send-btn:active { transform: scale(0.9); }
.chat-send-btn:disabled { opacity: 0.4; cursor: not-allowed; }
.chat-send-btn svg { width: 20px; height: 20px; }

/* Chat filter bar */
.chat-filter-bar {
    display: flex;
    gap: 8px;
    padding: 10px 16px 6px;
    background: var(--white);
}
.chat-filter-btn {
    padding: 6px 18px;
    border-radius: 20px;
    border: 1.5px solid var(--navy);
    background: transparent;
    color: var(--navy);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.15s ease;
}
.chat-filter-btn.active {
    background: var(--navy);
    color: white;
}
.chat-filter-btn:active { transform: scale(0.95); }

/* Read receipts (inline with timestamp) */
.chat-read-receipt {
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}
.chat-read-receipt.read { color: var(--teal); }
.chat-read-receipt.delivered { color: rgba(255,255,255,0.6); }

/* ============ 14. PROFILE VIEW ============ */
.profile-section {
    background: var(--white);
    padding: 20px;
    border-radius: 16px;
    margin: 8px 16px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.06), 0 0 1px rgba(0,0,0,0.08);
}

.profile-section-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--slate);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 12px;
}

.profile-photo-carousel {
    width: 100%;
    height: 280px;
    position: relative;
    overflow: hidden;
    border-radius: 0;
    background-color: var(--navy);
    background-size: contain;
    background-position: center;
    background-repeat: no-repeat;
}

.profile-photo-carousel img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.profile-photo-dots {
    position: absolute;
    bottom: 12px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 6px;
}

.profile-photo-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(255,255,255,0.5);
    transition: background 0.2s, transform 0.2s;
}
.profile-photo-dot.active {
    background: var(--white);
    transform: scale(1.2);
}

.profile-name-row {
    padding: 16px;
}

.profile-name {
    font-size: 26px;
    font-weight: 700;
    color: var(--text-primary);
}
.profile-name span {
    font-weight: 300;
    font-size: 22px;
}

.profile-location {
    font-size: 14px;
    color: var(--text-secondary);
    margin-top: 4px;
    display: flex;
    align-items: center;
    gap: 4px;
}

.profile-bio {
    font-size: 15px;
    line-height: 1.5;
    color: var(--text-primary);
}

.profile-detail-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid #f0f0f0;
}
.profile-detail-row:last-child { border-bottom: none; }

.profile-detail-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--soft-coral);
    border-radius: 8px;
    color: var(--coral);
    flex-shrink: 0;
}
.profile-detail-icon svg { width: 16px; height: 16px; }

.profile-detail-text {
    font-size: 14px;
    color: var(--text-primary);
}
.profile-detail-label {
    font-size: 12px;
    color: var(--text-secondary);
}

.profile-interests {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}
.profile-interest-tag {
    padding: 8px 14px;
    font-size: 13px;
    font-weight: 500;
    border-radius: 20px;
    background: var(--light-gray);
    color: var(--text-primary);
}

/* ============ 15. PROFILE DETAIL MODAL ============ */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    z-index: 200;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
.modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.modal-content {
    background: var(--white);
    width: 100%;
    max-width: 480px;
    max-height: 90vh;
    overflow: hidden;
    border-radius: 16px 16px 0 0;
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
    position: relative;
    display: flex;
    flex-direction: column;
}
.modal-scroll {
    overflow-y: auto;
    flex: 1;
    -webkit-overflow-scrolling: touch;
}
.modal-overlay.active .modal-content {
    transform: translateY(0);
}

.modal-handle {
    width: 40px;
    height: 4px;
    background: #ddd;
    border-radius: 2px;
    margin: 10px auto 0;
}

.modal-close {
    position: absolute;
    top: 12px;
    left: 12px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0,0,0,0.4);
    border: none;
    color: var(--white);
    font-size: 18px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
    transition: background 0.2s;
}
.modal-close:hover { background: rgba(0,0,0,0.6); }

/* ============ 15b. PEOPLE CARD VIEW ============ */
.people-card-view {
    padding: 8px 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
}
.people-swipe-wrapper {
    position: relative;
    width: 100%;
    max-width: 400px;
    touch-action: pan-y;
}
.people-card {
    position: relative;
    width: 100%;
    background: var(--white);
    border-radius: 20px;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0,0,0,0.15);
    transition: none;
    cursor: grab;
    user-select: none;
}
.people-card:active { cursor: grabbing; }
.people-card.swipe-left {
    transform: translateX(-150%) rotate(-30deg);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s ease;
}
.people-card.swipe-right {
    transform: translateX(150%) rotate(30deg);
    opacity: 0;
    transition: transform 0.25s ease, opacity 0.2s ease;
}

/* Swipe feedback stamps */
.people-card-stamp {
    position: absolute;
    top: 50px;
    padding: 8px 20px;
    font-size: 36px;
    font-weight: 800;
    letter-spacing: 2px;
    text-transform: uppercase;
    border: 4px solid;
    border-radius: 12px;
    opacity: 0;
    transition: opacity 0.15s;
    pointer-events: none;
    z-index: 30;
}
.people-stamp-like {
    left: 20px;
    color: var(--success);
    border-color: var(--success);
    transform: rotate(-15deg);
}
.people-stamp-nope {
    right: 20px;
    color: var(--error);
    border-color: var(--error);
    transform: rotate(15deg);
}

.people-card-photo {
    position: relative;
    width: 100%;
    aspect-ratio: 0.85;
    background-size: cover;
    background-position: center;
    background-color: var(--light-gray);
}
.people-photo-left, .people-photo-right {
    position: absolute;
    top: 0;
    bottom: 0;
    width: 50%;
    cursor: pointer;
    z-index: 5;
}
.people-photo-left { left: 0; }
.people-photo-right { right: 0; }
.people-photo-bars {
    position: absolute;
    top: 6px;
    left: 6px;
    right: 6px;
    display: flex;
    gap: 3px;
    z-index: 10;
}
.people-photo-bar {
    flex: 1;
    height: 3px;
    border-radius: 1.5px;
    background: rgba(255,255,255,0.4);
}
.people-photo-bar.active { background: white; }

.people-card-info {
    padding: 14px 16px;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
}
.people-card-name {
    font-size: 24px;
    font-weight: 800;
    color: white;
    text-shadow: 0 2px 6px rgba(0,0,0,0.5);
}
.people-card-location {
    font-size: 14px;
    color: rgba(255,255,255,0.9);
    margin-top: 2px;
}
.people-card-bio {
    font-size: 13px;
    color: rgba(255,255,255,0.85);
    margin-top: 6px;
    line-height: 1.4;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.people-block-report {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 8px 0;
}
.people-block-btn, .people-report-btn {
    background: none;
    border: none;
    font-size: 13px;
    cursor: pointer;
    padding: 4px 8px;
}
.people-block-btn { color: var(--text-secondary); font-weight: 500; }
.people-block-btn:hover { text-decoration: underline; }
.people-block-divider { color: #ddd; font-size: 13px; }
.people-report-btn { color: var(--coral); font-weight: 500; }
.people-report-btn:hover { text-decoration: underline; }

.people-action-row {
    display: flex;
    gap: 12px;
    padding: 4px 0 8px;
    align-items: center;
    justify-content: center;
    width: 100%;
    max-width: 400px;
}
.people-notforme-btn, .people-like-btn {
    flex: 1;
    padding: 14px;
    border-radius: 999px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}
.people-notforme-btn {
    background: white;
    border: 1.5px solid var(--navy);
    color: var(--navy);
}
.people-notforme-btn:hover { background: #f8f8f8; }
.people-like-btn {
    background: var(--coral);
    border: 1.5px solid var(--coral);
    color: white;
    box-shadow: 0 4px 12px rgba(255,107,107,0.3);
}
.people-like-btn:hover { background: #ff5252; }
.people-info-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: #f0f0f0;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--coral);
    flex-shrink: 0;
}
.people-info-btn:hover { background: #e0e0e0; }
.people-counter {
    text-align: center;
    font-size: 12px;
    color: var(--text-secondary);
    padding: 4px 0;
}

/* ============ 16. EDIT PROFILE FORM ============ */
.form-body { padding: 20px 24px; }

.section-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--slate);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin: 28px 0 14px 0;
    padding-bottom: 8px;
    border-bottom: 1px solid #eee;
}
.section-title:first-child { margin-top: 0; }

.field-group { margin-bottom: 16px; }
.field-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 6px;
}
.field-required::after {
    content: ' *';
    color: var(--coral);
}

.field-input,
.field-select,
.field-textarea {
    width: 100%;
    padding: 14px 16px;
    font-size: 16px;
    border: 1px solid var(--input-border);
    border-radius: 10px;
    background: var(--input-bg);
    color: var(--text-primary);
    outline: none;
    -webkit-appearance: none;
    appearance: none;
    transition: border-color 0.2s, background 0.2s;
}
.field-input:focus,
.field-select:focus,
.field-textarea:focus {
    border-color: var(--coral);
    background: var(--white);
}
.field-select {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath d='M6 8L1 3h10z' fill='%236C7B95'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 16px center;
    padding-right: 40px;
}
.field-textarea {
    min-height: 80px;
    resize: vertical;
    font-family: inherit;
}

/* Toggle buttons (gender, yes/no) */
.toggle-group { display: flex; gap: 8px; }
.toggle-btn {
    flex: 1;
    padding: 12px;
    font-size: 15px;
    font-weight: 600;
    border: 2px solid var(--input-border);
    border-radius: 10px;
    background: var(--input-bg);
    color: var(--text-secondary);
    cursor: pointer;
    text-align: center;
    transition: all 0.15s;
}
.toggle-btn.selected {
    border-color: var(--coral);
    background: linear-gradient(135deg, #FFE5E5 0%, #fff0f0 100%);
    color: var(--coral);
    box-shadow: 0 2px 8px rgba(255,107,107,0.15);
}

/* Multi-select chips */
.chip-group { display: flex; flex-wrap: wrap; gap: 8px; }
.chip {
    padding: 10px 16px;
    font-size: 14px;
    font-weight: 500;
    border: 2px solid var(--input-border);
    border-radius: 20px;
    background: var(--input-bg);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}
.chip.selected {
    border-color: var(--coral);
    background: var(--soft-coral);
    color: var(--coral);
}

.height-row { display: flex; gap: 12px; }
.height-row .field-group { flex: 1; }

/* Photo grid in edit */
.photo-grid {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
    padding: 16px 0;
}
.photo-slot {
    aspect-ratio: 3/4;
    border: 2px dashed var(--input-border);
    border-radius: var(--radius);
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    cursor: pointer;
    overflow: hidden;
    position: relative;
    background: var(--input-bg);
    transition: border-color 0.2s;
}
.photo-slot:hover { border-color: var(--coral); }
.photo-slot.has-photo { border-style: solid; border-color: transparent; }
.photo-slot img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}
.photo-add-icon {
    font-size: 28px;
    color: var(--text-light);
    margin-bottom: 4px;
}
.photo-add-text {
    font-size: 11px;
    color: var(--text-light);
}
.photo-primary-badge {
    position: absolute;
    top: 6px;
    left: 6px;
    background: var(--coral);
    color: var(--white);
    font-size: 9px;
    font-weight: 700;
    padding: 3px 6px;
    border-radius: 4px;
    text-transform: uppercase;
}
.photo-delete {
    position: absolute;
    top: 6px;
    right: 6px;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: rgba(0,0,0,0.5);
    color: var(--white);
    border: none;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.photo-delete:hover { background: rgba(0,0,0,0.7); }
.photo-actions {
    position: absolute;
    bottom: 6px;
    left: 6px;
    right: 6px;
    display: flex;
    gap: 4px;
    justify-content: center;
}
.photo-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(0,0,0,0.55);
    color: var(--white);
    border: none;
    font-size: 14px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}
.photo-action-btn:hover { background: rgba(0,0,0,0.8); }
.photo-action-btn.primary-btn { background: var(--coral); }
.photo-action-btn.primary-btn:hover { background: #e55a5a; }

/* Edit profile button */
.edit-profile-btn {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 100%);
    color: var(--white);
    cursor: pointer;
    margin-top: 12px;
    transition: all 0.25s;
    box-shadow: 0 6px 24px rgba(255,107,107,0.35);
    letter-spacing: 0.5px;
}
.edit-profile-btn:active { transform: scale(0.97); box-shadow: 0 3px 12px rgba(255,107,107,0.3); }

/* Photo grid in edit mode */
.photo-grid-edit {
    display: grid;
    grid-template-columns: 1fr 1fr 1fr;
    gap: 10px;
    margin-top: 8px;
}

/* Settings badge */
.settings-badge {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 700;
    background: var(--light-gray);
    color: var(--slate);
}

/* Range input */
.range-input {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: var(--input-border);
    outline: none;
}
.range-input::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--coral);
    cursor: pointer;
    border: 2px solid var(--white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.range-input::-moz-range-thumb {
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: var(--coral);
    cursor: pointer;
    border: 2px solid var(--white);
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}

/* Save bar */
.save-bar {
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: var(--white);
    padding: 16px 24px 80px 24px;
    border-top: 1px solid #eee;
    z-index: 10;
}
.save-bar-inner {
    max-width: 480px;
    margin: 0 auto;
}
.save-btn {
    width: 100%;
    padding: 16px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    background: linear-gradient(135deg, #FF6B6B 0%, #FF8E8E 100%);
    color: var(--white);
    cursor: pointer;
    transition: all 0.25s;
    box-shadow: 0 6px 24px rgba(255,107,107,0.3);
    box-shadow: 0 4px 16px rgba(255,107,107,0.3);
}
.save-btn:active { opacity: 0.8; transform: scale(0.98); }
.save-btn:disabled { opacity: 0.5; cursor: not-allowed; transform: none; }

/* ============ 17. SETTINGS PANEL ============ */
.settings-panel {
    background: var(--white);
}

.settings-section {
    padding: 16px;
    border-bottom: 8px solid var(--light-gray);
}

.settings-section-title {
    font-size: 13px;
    font-weight: 700;
    color: var(--slate);
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 16px;
}

.settings-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
}
.settings-row:last-child { border-bottom: none; }

.settings-row-icon {
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-gray);
    border-radius: 10px;
    flex-shrink: 0;
}
.settings-row-icon svg { width: 20px; height: 20px; color: var(--slate); }

.settings-row-text {
    flex: 1;
}
.settings-row-label {
    font-size: 15px;
    font-weight: 600;
    color: var(--text-primary);
}
.settings-row-desc {
    font-size: 13px;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* CSS-only toggle switch */
.toggle-switch {
    position: relative;
    width: 48px;
    height: 26px;
    flex-shrink: 0;
}
.toggle-switch input {
    opacity: 0;
    width: 0;
    height: 0;
    position: absolute;
}
.toggle-slider {
    position: absolute;
    cursor: pointer;
    inset: 0;
    background: #ccc;
    border-radius: 26px;
    transition: background 0.25s;
}
.toggle-slider::before {
    content: '';
    position: absolute;
    width: 22px;
    height: 22px;
    left: 2px;
    bottom: 2px;
    background: var(--white);
    border-radius: 50%;
    transition: transform 0.25s;
    box-shadow: 0 1px 3px rgba(0,0,0,0.2);
}
.toggle-switch input:checked + .toggle-slider {
    background: linear-gradient(135deg, #FF6B6B, #FF8E8E);
    box-shadow: 0 2px 8px rgba(255,107,107,0.3);
}
.toggle-switch input:checked + .toggle-slider::before {
    transform: translateX(22px);
}

/* Duration chips for snooze */
.duration-chips {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}
.duration-chip {
    padding: 8px 16px;
    font-size: 13px;
    font-weight: 600;
    border: 2px solid var(--input-border);
    border-radius: 20px;
    background: var(--input-bg);
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.15s;
}
.duration-chip.selected {
    border-color: var(--coral);
    background: var(--soft-coral);
    color: var(--coral);
}

.settings-link {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 0;
    border-bottom: 1px solid #f0f0f0;
    cursor: pointer;
}
.settings-link:last-child { border-bottom: none; }
.settings-link-text {
    font-size: 15px;
    color: var(--text-primary);
}
.settings-link-arrow {
    color: var(--text-light);
    font-size: 18px;
}

.settings-danger {
    color: var(--error);
    font-weight: 600;
}

.settings-logout {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    border: 2px solid var(--error);
    border-radius: var(--radius);
    background: transparent;
    color: var(--error);
    cursor: pointer;
    margin: 16px 0;
    transition: all 0.2s;
}
.settings-logout:active {
    background: var(--error);
    color: var(--white);
}

/* ============ 18. TOAST ============ */
.toast {
    position: fixed;
    top: 76px;
    left: 50%;
    transform: translateX(-50%) translateY(-200%);
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 600;
    color: var(--white);
    z-index: 9999;
    transition: transform 0.4s cubic-bezier(0.68, -0.55, 0.27, 1.55), opacity 0.3s, visibility 0.3s;
    box-shadow: 0 8px 32px rgba(0,0,0,0.25);
    max-width: calc(100% - 48px);
    text-align: center;
    visibility: hidden;
    opacity: 0;
    pointer-events: none;
}
.toast.visible {
    transform: translateX(-50%) translateY(0);
    visibility: visible;
    opacity: 1;
    pointer-events: auto;
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
}
.toast.success { background: rgba(39,174,96,0.95); }
.toast.error { background: rgba(231,76,60,0.95); }
.toast.info { background: rgba(27,51,88,0.95); }

/* ============ 19. MATCH POPUP ============ */
.match-popup {
    position: fixed;
    inset: 0;
    z-index: 300;
    background: linear-gradient(135deg, rgba(15,32,39,0.97) 0%, rgba(27,51,88,0.97) 50%, rgba(42,74,127,0.97) 100%);
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.4s, visibility 0.4s;
}
.match-popup.active {
    opacity: 1;
    visibility: visible;
}

.match-popup-title {
    font-family: 'Playfair Display', Georgia, serif;
    font-size: 36px;
    font-weight: 800;
    color: var(--coral);
    margin-bottom: 8px;
    text-shadow: 0 2px 8px rgba(255,107,107,0.3);
}

.match-popup-subtitle {
    font-size: 15px;
    color: rgba(255,255,255,0.7);
    margin-bottom: 32px;
}

.match-popup-photos {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.match-popup-photo {
    width: 110px;
    height: 110px;
    border-radius: 50%;
    border: 4px solid var(--coral);
    object-fit: cover;
    box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

.match-popup-heart {
    font-size: 28px;
    color: var(--coral);
    animation: matchPulse 1s ease-in-out infinite;
}

@keyframes matchPulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.match-popup-btn {
    width: 100%;
    max-width: 280px;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    margin-bottom: 12px;
    transition: opacity 0.2s, transform 0.1s;
}
.match-popup-btn:active { opacity: 0.8; transform: scale(0.97); }

.match-popup-btn-message {
    background: var(--coral);
    color: var(--white);
    box-shadow: 0 4px 16px rgba(255,107,107,0.4);
}

.match-popup-btn-continue {
    background: transparent;
    color: var(--white);
    border: 2px solid rgba(255,255,255,0.3);
}

/* ============ MESSAGE ALERT OVERLAY ============ */
.msg-alert-overlay {
    position: fixed;
    inset: 0;
    z-index: 400;
    background: rgba(0,0,0,0.85);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 30px;
    text-align: center;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
.msg-alert-overlay.active {
    opacity: 1;
    visibility: visible;
}
.msg-alert-card {
    background: var(--white);
    border-radius: 24px;
    padding: 32px 24px;
    max-width: 340px;
    width: 100%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 80px rgba(255,107,107,0.3);
    animation: msgAlertBounce 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    overflow: hidden;
}
@keyframes msgAlertBounce {
    0% { transform: scale(0.3) translateY(60px); opacity: 0; }
    100% { transform: scale(1) translateY(0); opacity: 1; }
}
.msg-alert-glow {
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    border-radius: 26px;
    background: linear-gradient(135deg, var(--coral), var(--gold), var(--teal), var(--coral));
    background-size: 300% 300%;
    animation: msgGlowShift 2s ease infinite;
    z-index: -1;
}
@keyframes msgGlowShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
.msg-alert-bell {
    font-size: 48px;
    animation: msgBellRing 0.6s ease-in-out 3;
    display: inline-block;
    margin-bottom: 8px;
}
@keyframes msgBellRing {
    0%, 100% { transform: rotate(0); }
    15% { transform: rotate(18deg); }
    30% { transform: rotate(-16deg); }
    45% { transform: rotate(14deg); }
    60% { transform: rotate(-10deg); }
    75% { transform: rotate(6deg); }
    90% { transform: rotate(-2deg); }
}
.msg-alert-title {
    font-size: 22px;
    font-weight: 800;
    color: var(--coral);
    margin-bottom: 6px;
}
.msg-alert-from {
    font-size: 16px;
    color: var(--text-primary);
    font-weight: 600;
    margin-bottom: 16px;
}
.msg-alert-photo {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    border: 4px solid var(--coral);
    object-fit: cover;
    margin: 0 auto 16px;
    display: block;
    box-shadow: 0 4px 20px rgba(255,107,107,0.3);
    animation: msgPhotoPulse 1.5s ease-in-out infinite;
}
@keyframes msgPhotoPulse {
    0%, 100% { box-shadow: 0 4px 20px rgba(255,107,107,0.3); }
    50% { box-shadow: 0 4px 30px rgba(255,107,107,0.6), 0 0 40px rgba(255,107,107,0.2); }
}
.msg-alert-preview {
    background: var(--light-gray);
    border-radius: 12px;
    padding: 12px 16px;
    font-size: 14px;
    color: var(--text-primary);
    margin-bottom: 20px;
    font-style: italic;
    max-height: 60px;
    overflow: hidden;
}
.msg-alert-btn {
    width: 100%;
    padding: 16px;
    font-size: 16px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    cursor: pointer;
    margin-bottom: 10px;
    transition: transform 0.1s;
}
.msg-alert-btn:active { transform: scale(0.97); }
.msg-alert-btn-read {
    background: var(--coral);
    color: var(--white);
    box-shadow: 0 4px 16px rgba(255,107,107,0.4);
}
.msg-alert-btn-later {
    background: transparent;
    color: var(--slate);
    font-size: 14px;
}

/* ============ BEACON ALERT OVERLAY ============ */
.beacon-alert-overlay {
    position: fixed; inset: 0; z-index: 450;
    background: rgba(0,0,0,0.9);
    display: flex; flex-direction: column;
    align-items: center; justify-content: center;
    padding: 30px; text-align: center;
    opacity: 0; visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
.beacon-alert-overlay.active { opacity: 1; visibility: visible; }
.beacon-alert-card {
    background: var(--white); border-radius: 24px;
    padding: 28px 24px; max-width: 340px; width: 100%;
    box-shadow: 0 20px 60px rgba(0,0,0,0.5), 0 0 80px rgba(255,68,68,0.4);
    animation: msgAlertBounce 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative; overflow: hidden;
}
.beacon-alert-card::before {
    content: ''; position: absolute; top: -2px; left: -2px; right: -2px; bottom: -2px;
    border-radius: 26px;
    background: linear-gradient(135deg, #FF4444, #FFD93D, #FF4444, #FFD93D);
    background-size: 300% 300%;
    animation: msgGlowShift 1.5s ease infinite;
    z-index: -1;
}
.beacon-alert-icon {
    font-size: 56px; margin-bottom: 4px;
    animation: beaconAlertPulse 0.5s ease-in-out infinite alternate;
}
@keyframes beaconAlertPulse {
    0% { transform: scale(1); }
    100% { transform: scale(1.15); }
}
.beacon-alert-title {
    font-size: 20px; font-weight: 800; margin-bottom: 4px;
}
.beacon-alert-court {
    font-size: 16px; font-weight: 700; color: var(--navy); margin-bottom: 2px;
}
.beacon-alert-sub {
    font-size: 14px; color: var(--slate); margin-bottom: 16px;
}
.beacon-alert-body {
    background: var(--light-gray); border-radius: 12px;
    padding: 12px 16px; font-size: 15px; color: var(--text-primary);
    margin-bottom: 20px; font-weight: 600;
}
.beacon-alert-btn {
    width: 100%; padding: 16px; font-size: 16px; font-weight: 700;
    border: none; border-radius: 30px; cursor: pointer; margin-bottom: 10px;
    touch-action: manipulation;
}
.beacon-alert-btn-go {
    background: linear-gradient(135deg, var(--teal), #38b2ac);
    color: white; box-shadow: 0 4px 16px rgba(78,205,196,0.4);
}
.beacon-alert-btn-dismiss {
    background: transparent; color: var(--slate); font-size: 14px;
}

/* ============ 20. FILTER MODAL ============ */
.filter-modal {
    position: fixed;
    inset: 0;
    z-index: 250;
    display: flex;
    align-items: flex-end;
    justify-content: center;
    background: rgba(0,0,0,0.5);
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s, visibility 0.3s;
}
.filter-modal.active {
    opacity: 1;
    visibility: visible;
}

.filter-content {
    background: var(--white);
    width: 100%;
    max-width: 480px;
    max-height: 80vh;
    overflow-y: auto;
    border-radius: 16px 16px 0 0;
    padding: 20px 24px 40px;
    transform: translateY(100%);
    transition: transform 0.35s cubic-bezier(0.32, 0.72, 0, 1);
}
.filter-modal.active .filter-content {
    transform: translateY(0);
}

.filter-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 24px;
}
.filter-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
}
.filter-reset {
    font-size: 14px;
    font-weight: 600;
    color: var(--coral);
    background: none;
    border: none;
    cursor: pointer;
}

.filter-section {
    margin-bottom: 24px;
}
.filter-label {
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: 12px;
    display: flex;
    justify-content: space-between;
}
.filter-label-value {
    color: var(--coral);
    font-weight: 700;
}

/* Range slider */
.range-slider {
    position: relative;
    height: 36px;
    display: flex;
    align-items: center;
}
.range-slider input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: #e0e0e0;
    outline: none;
}
.range-slider input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--coral);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(255,107,107,0.3);
    border: 3px solid var(--white);
}

/* Dual range display */
.dual-range {
    position: relative;
    height: 36px;
}
.dual-range input[type="range"] {
    -webkit-appearance: none;
    appearance: none;
    width: 100%;
    height: 4px;
    border-radius: 2px;
    background: transparent;
    outline: none;
    position: absolute;
    pointer-events: none;
}
.dual-range input[type="range"]::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: var(--coral);
    cursor: pointer;
    box-shadow: 0 2px 8px rgba(255,107,107,0.3);
    border: 3px solid var(--white);
    pointer-events: auto;
}
.dual-range-track {
    position: absolute;
    height: 4px;
    border-radius: 2px;
    background: #e0e0e0;
    top: 50%;
    left: 0;
    right: 0;
    transform: translateY(-50%);
}
.dual-range-fill {
    position: absolute;
    height: 4px;
    border-radius: 2px;
    background: var(--coral);
    top: 50%;
    transform: translateY(-50%);
}

.filter-gender-toggles {
    display: flex;
    gap: 8px;
}
.filter-gender-btn {
    flex: 1;
    padding: 12px;
    font-size: 14px;
    font-weight: 600;
    border: 2px solid var(--input-border);
    border-radius: 10px;
    background: var(--input-bg);
    color: var(--text-secondary);
    cursor: pointer;
    text-align: center;
    transition: all 0.15s;
}
.filter-gender-btn.selected {
    border-color: var(--coral);
    background: var(--soft-coral);
    color: var(--coral);
}

.filter-apply-btn {
    width: 100%;
    padding: 16px;
    font-size: 17px;
    font-weight: 700;
    border: none;
    border-radius: var(--radius);
    background: var(--coral);
    color: var(--white);
    cursor: pointer;
    margin-top: 8px;
    transition: opacity 0.2s, transform 0.1s;
    box-shadow: 0 4px 16px rgba(255,107,107,0.3);
}
.filter-apply-btn:active { opacity: 0.8; transform: scale(0.98); }

/* ============ 21. EMPTY STATES ============ */
.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 32px;
    text-align: center;
}

.empty-state-icon {
    font-size: 56px;
    margin-bottom: 16px;
}

.empty-state-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 8px;
}

.empty-state-subtitle {
    font-size: 14px;
    color: var(--text-secondary);
    line-height: 1.5;
    max-width: 280px;
}

.empty-state-btn {
    margin-top: 24px;
    padding: 12px 32px;
    font-size: 15px;
    font-weight: 700;
    border: none;
    border-radius: 30px;
    background: var(--coral);
    color: var(--white);
    cursor: pointer;
    transition: opacity 0.2s;
}
.empty-state-btn:active { opacity: 0.8; }

/* ============ 22. LOADING SPINNER ============ */
.spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--input-border);
    border-top-color: var(--coral);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    will-change: transform;
    -webkit-transform: translateZ(0);
}

.spinner-sm {
    width: 20px;
    height: 20px;
    border-width: 2px;
}

.spinner-lg {
    width: 48px;
    height: 48px;
    border-width: 4px;
}

@keyframes spin {
    to { transform: rotate(360deg); }
}

.loading-screen {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    min-height: 200px;
    gap: 16px;
}

.loading-text {
    font-size: 14px;
    color: var(--text-secondary);
}

/* ============ 23. UTILITY CLASSES ============ */
.hidden { display: none !important; }
.mt-4 { margin-top: 4px; }
.mt-8 { margin-top: 8px; }
.mt-12 { margin-top: 12px; }
.mt-16 { margin-top: 16px; }
.mt-24 { margin-top: 24px; }
.mt-32 { margin-top: 32px; }
.mb-4 { margin-bottom: 4px; }
.mb-8 { margin-bottom: 8px; }
.mb-16 { margin-bottom: 16px; }
.mb-24 { margin-bottom: 24px; }
.p-16 { padding: 16px; }
.px-16 { padding-left: 16px; padding-right: 16px; }
.py-8 { padding-top: 8px; padding-bottom: 8px; }
.text-center { text-align: center; }
.text-coral { color: var(--coral); }
.text-slate { color: var(--slate); }
.text-sm { font-size: 13px; }
.text-xs { font-size: 11px; }
.font-bold { font-weight: 700; }
.w-full { width: 100%; }
.flex { display: flex; }
.flex-col { flex-direction: column; }
.items-center { align-items: center; }
.justify-center { justify-content: center; }
.justify-between { justify-content: space-between; }
.gap-8 { gap: 8px; }
.gap-12 { gap: 12px; }
.gap-16 { gap: 16px; }

/* ============ 24. SCROLLBAR STYLING ============ */
::-webkit-scrollbar {
    width: 4px;
}
::-webkit-scrollbar-track {
    background: transparent;
}
::-webkit-scrollbar-thumb {
    background: rgba(27,51,88,0.2);
    border-radius: 4px;
}
::-webkit-scrollbar-thumb:hover {
    background: rgba(27,51,88,0.4);
}

/* Horizontal scrollbar for matches */
.new-matches::-webkit-scrollbar {
    height: 0;
}

/* Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: rgba(27,51,88,0.2) transparent;
}
/* ============ JS-GENERATED CLASS ALIASES ============ */
/* Grid cards (used by renderLikesGrid, renderPeopleGrid) */
.grid-card {
    aspect-ratio: 4/5;
    border-radius: 16px;
    overflow: hidden;
    position: relative;
    background-size: cover;
    background-position: center;
    background-color: var(--navy);
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,0.12), 0 1px 4px rgba(0,0,0,0.08);
    transition: transform 0.2s ease, box-shadow 0.2s ease;
    will-change: transform;
    -webkit-transform: translateZ(0);
    transform: translateZ(0);
}
.grid-card:active { transform: scale(0.96); }
.grid-card:hover { box-shadow: 0 8px 32px rgba(0,0,0,0.18); }
.grid-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 40px 14px 14px;
    background: linear-gradient(to top, rgba(0,0,0,0.75) 0%, rgba(0,0,0,0.2) 60%, transparent 100%);
}
.grid-name {
    font-size: 16px;
    font-weight: 700;
    color: var(--white);
}
.grid-location {
    font-size: 12px;
    color: rgba(255,255,255,0.8);
    margin-top: 2px;
}
.grid-badge {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 18px;
}
.grid-status-banner {
    position: absolute;
    top: 10px;
    right: 8px;
    padding: 4px 10px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 800;
    letter-spacing: 0.5px;
    color: #fff;
    text-transform: uppercase;
    z-index: 5;
    text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.grid-mode-banner {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 4;
    pointer-events: none;
    display: flex;
    align-items: center;
    justify-content: center;
}
.grid-mode-banner::before {
    content: attr(data-label);
    display: none;
}
.grid-mode-snoozed {
    background: rgba(27, 51, 88, 0.55);
    font-size: 16px;
    font-weight: 900;
    color: #fff;
    letter-spacing: 3px;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    transform: rotate(-25deg);
}
.grid-mode-incognito {
    background: rgba(108, 123, 149, 0.55);
    font-size: 14px;
    font-weight: 900;
    color: #fff;
    letter-spacing: 3px;
    text-transform: uppercase;
    text-shadow: 0 2px 8px rgba(0,0,0,0.5);
    transform: rotate(-25deg);
}
.grid-reset-btn {
    position: absolute;
    top: 10px;
    left: 8px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(0,0,0,0.55);
    color: white;
    border: none;
    font-size: 18px;
    cursor: pointer;
    z-index: 6;
    display: flex;
    align-items: center;
    justify-content: center;
    backdrop-filter: blur(4px);
    -webkit-backdrop-filter: blur(4px);
}
.grid-reset-btn:hover { background: rgba(255,107,107,0.8); }

/* Chat rows (used by renderChatList) */
.chat-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    background: var(--white);
    cursor: pointer;
    border-bottom: 1px solid #f0f0f0;
    transition: background 0.15s;
}
.chat-row:active { background: var(--light-gray); }
.chat-avatar {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    flex-shrink: 0;
    background-size: cover;
    background-position: center;
    background-color: var(--input-bg);
}
.chat-info {
    flex: 1;
    min-width: 0;
}
.chat-name {
    font-size: 15px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 2px;
}
.chat-preview {
    font-size: 13px;
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}
.chat-meta {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}
.chat-time {
    font-size: 11px;
    color: var(--text-light);
}
.chat-unread {
    background: var(--coral);
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    min-width: 20px;
    height: 20px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0 6px;
}

/* New match avatars (used by renderChatList) */
.new-match-avatar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
    cursor: pointer;
}
.match-circle {
    width: 62px;
    height: 62px;
    border-radius: 50%;
    border: 3px solid var(--coral);
    background-size: cover;
    background-position: center;
    background-color: var(--input-bg);
}
.match-name {
    font-size: 12px;
    font-weight: 500;
    color: var(--text-primary);
    max-width: 68px;
    text-align: center;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Loading */
.loading-wrap {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 40px;
}

/* Modal photo/body */
.modal-photo {
    width: 100%;
    aspect-ratio: 4/5;
    background-size: cover;
    background-position: center;
    background-color: var(--navy);
}
.modal-body {
    padding: 0;
}

/* ============ DINK LIFE OVERLAY ============ */
.dinklife-overlay {
    position: fixed;
    inset: 0;
    z-index: 200;
    background: rgba(0,0,0,0.5);
    display: none;
    justify-content: center;
    align-items: stretch;
}
.dinklife-overlay.active { display: flex; }
.dinklife-overlay-content {
    background: var(--light-gray);
    display: flex;
    flex-direction: column;
    max-width: 480px;
    width: 100%;
    margin: 0 auto;
    overflow-x: hidden;
}
.dinklife-header {
    background: var(--navy);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    gap: 12px;
}
.dinklife-back {
    background: none;
    border: none;
    color: var(--white);
    font-size: 24px;
    cursor: pointer;
    padding: 4px;
}
.dinklife-body {
    flex: 1;
    overflow-y: auto;
    overflow-x: hidden;
    -webkit-overflow-scrolling: touch;
}
.dinklife-hub-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    padding: 12px;
}
.dinklife-cat-card {
    aspect-ratio: 1;
    border-radius: 16px;
    padding: 16px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 12px rgba(0,0,0,0.15);
    transition: transform 0.15s;
    text-align: center;
}
.dinklife-cat-card:active { transform: scale(0.96); }
.dinklife-cat-card.full-width {
    grid-column: 1 / -1;
    aspect-ratio: 2.2;
}
.dinklife-cat-icon {
    width: 72px;
    height: 72px;
    border-radius: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 10px;
    font-size: 36px;
}
.dinklife-cat-name {
    font-size: 16px;
    font-weight: 900;
    color: var(--white);
}
.dinklife-cat-sub {
    font-size: 12px;
    font-weight: 600;
    color: rgba(255,255,255,0.8);
    margin-top: 2px;
}

/* Category detail */
.dinklife-cat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 12px 16px;
    gap: 12px;
}
.dinklife-cat-title {
    font-size: 20px;
    font-weight: 900;
    color: var(--white);
}
.dinklife-item-card {
    background: var(--white);
    border-radius: 12px;
    margin: 0 0 12px;
    overflow: hidden;
    box-shadow: 0 2px 6px rgba(0,0,0,0.1);
    position: relative;
}
.dinklife-item-card.featured { border: 2px solid; }
.dinklife-featured-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    z-index: 5;
    padding: 3px 8px;
    border-radius: 6px;
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 4px;
}
.dinklife-item-img {
    width: 100%;
    object-fit: contain;
    max-height: 300px;
    background: #f8f8f8;
}
.dinklife-item-body { padding: 14px; }
.dinklife-item-title {
    font-size: 16px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 6px;
}
.dinklife-detail-row {
    display: flex;
    align-items: flex-start;
    gap: 6px;
    margin-bottom: 5px;
    font-size: 13px;
    color: var(--text-secondary);
}
.dinklife-detail-icon {
    flex-shrink: 0;
    font-size: 14px;
}
.dinklife-item-desc {
    font-size: 13px;
    color: var(--text-secondary);
    line-height: 1.5;
    margin: 8px 0;
}
.dinklife-payment-notes {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    background: #E3F2FD;
    padding: 10px 12px;
    border-radius: 8px;
    margin: 8px 0;
    font-size: 13px;
    color: #1565C0;
    line-height: 1.5;
}
.dinklife-deposit-badge {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    background: #E65100;
    color: var(--white);
    padding: 7px 14px;
    border-radius: 8px;
    margin: 6px 0;
    font-size: 13px;
    font-weight: 700;
}
.dinklife-map {
    width: 100%;
    height: 140px;
    object-fit: cover;
    border-radius: 8px;
    margin-top: 6px;
    cursor: pointer;
}
.dinklife-actions {
    display: flex;
    gap: 8px;
    margin-top: 12px;
}
.dinklife-action-btn {
    flex: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 11px;
    border-radius: 8px;
    border: none;
    color: var(--white);
    font-size: 13px;
    font-weight: 700;
    cursor: pointer;
    transition: opacity 0.2s;
}
.dinklife-action-btn:active { opacity: 0.8; }

/* Pricing box */
.dinklife-pricing-box {
    background: #F8F9FA;
    border-radius: 8px;
    margin: 8px 0;
    overflow: hidden;
}
.dinklife-promo-banner {
    background: #E65100;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 5px 10px;
    color: var(--white);
    font-size: 11px;
    font-weight: 700;
}
.dinklife-pricing-row {
    display: flex;
    padding: 10px;
}
.dinklife-pricing-tier {
    flex: 1;
    text-align: center;
}
.dinklife-pricing-divider {
    width: 1px;
    background: #DEE2E6;
    margin: 0 8px;
}
.dinklife-pricing-label {
    font-size: 10px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
}
.dinklife-pricing-label-premium {
    font-size: 10px;
    font-weight: 600;
    color: #7B2D8E;
}
.dinklife-pricing-amount {
    font-size: 18px;
    font-weight: 900;
    color: var(--text-primary);
}
.dinklife-pricing-amount.muted { color: var(--text-light); }
.dinklife-pricing-amount.premium { color: #7B2D8E; }
.dinklife-pricing-strike {
    font-size: 11px;
    color: var(--text-light);
    text-decoration: line-through;
    margin-top: 2px;
}
.dinklife-pricing-savings {
    font-size: 11px;
    color: #2E7D32;
    font-weight: 600;
    margin-top: 2px;
}
.dinklife-empty {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 30px;
    text-align: center;
}
.dinklife-empty-icon {
    width: 100px;
    height: 100px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 48px;
    margin-bottom: 16px;
}

/* Admin overlay */
.admin-overlay {
    position: fixed;
    inset: 0;
    z-index: 210;
    background: rgba(0,0,0,0.5);
    display: none;
    justify-content: center;
    align-items: stretch;
}
.admin-overlay.active { display: flex; }
.admin-overlay-content {
    background: var(--light-gray);
    display: flex;
    flex-direction: column;
    max-width: 480px;
    width: 100%;
    margin: 0 auto;
    overflow-x: hidden;
}
.admin-body { flex: 1; overflow-y: auto; overflow-x: hidden; -webkit-overflow-scrolling: touch; padding: 12px; }
.admin-cat-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
}
.admin-cat-card {
    border-radius: 12px;
    padding: 16px;
    cursor: pointer;
    text-align: center;
    color: var(--white);
    box-shadow: 0 3px 10px rgba(0,0,0,0.15);
    transition: transform 0.15s;
}
.admin-cat-card:active { transform: scale(0.96); }
.admin-cat-icon { font-size: 32px; margin-bottom: 8px; }
.admin-cat-name { font-size: 14px; font-weight: 700; }
.admin-cat-count { font-size: 11px; opacity: 0.8; margin-top: 4px; }
.admin-item-row {
    background: var(--white);
    border-radius: 10px;
    padding: 12px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 1px 4px rgba(0,0,0,0.08);
}
.admin-item-info { flex: 1; }
.admin-item-title { font-size: 14px; font-weight: 700; color: var(--text-primary); }
.admin-item-meta { font-size: 12px; color: var(--text-secondary); margin-top: 2px; }
.admin-item-actions { display: flex; gap: 8px; }
.admin-small-btn {
    padding: 6px 12px;
    border-radius: 6px;
    border: none;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    color: var(--white);
}
.admin-form-group {
    margin-bottom: 12px;
}
.admin-form-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: var(--text-secondary);
    margin-bottom: 4px;
}
.admin-form-input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--input-border);
    border-radius: 8px;
    font-size: 14px;
    background: var(--input-bg);
}
.admin-form-textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--input-border);
    border-radius: 8px;
    font-size: 14px;
    background: var(--input-bg);
    min-height: 80px;
    resize: vertical;
}
.admin-dropzone {
    border: 2px dashed var(--input-border);
    border-radius: 12px;
    padding: 24px 16px;
    text-align: center;
    cursor: pointer;
    transition: all 0.2s;
    background: var(--input-bg);
    position: relative;
}
.admin-dropzone.dragover {
    border-color: var(--coral);
    background: rgba(255,107,107,0.06);
}
.admin-dropzone-icon {
    font-size: 32px;
    margin-bottom: 6px;
}
.admin-dropzone-text {
    font-size: 14px;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 4px;
}
.admin-dropzone-hint {
    font-size: 12px;
    color: var(--text-secondary);
}
.admin-dropzone-preview {
    position: relative;
    display: inline-block;
}
.admin-dropzone-preview img {
    max-width: 100%;
    max-height: 200px;
    border-radius: 8px;
    object-fit: cover;
}
.admin-dropzone-remove {
    position: absolute;
    top: -8px;
    right: -8px;
    width: 24px;
    height: 24px;
    border-radius: 12px;
    background: var(--error);
    color: var(--white);
    border: none;
    font-size: 14px;
    font-weight: 800;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}
.admin-dropzone-uploading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--text-secondary);
    font-size: 13px;
    font-weight: 600;
}
.admin-image-or {
    text-align: center;
    font-size: 12px;
    font-weight: 700;
    color: var(--text-light);
    margin: 8px 0 4px;
    text-transform: uppercase;
    letter-spacing: 1px;
}
.admin-toggle-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
}

/* ============ CHAT NOTIFICATION POPUP ============ */
.chat-notify-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 9999;
    display: flex;
    justify-content: center;
    padding: 12px 16px;
    transform: translateY(-120%);
    transition: transform 0.45s cubic-bezier(0.34, 1.56, 0.64, 1);
    pointer-events: none;
}
.chat-notify-overlay.active {
    transform: translateY(0);
    pointer-events: auto;
}
.chat-notify-card {
    width: 100%;
    max-width: 420px;
    background: rgba(255, 255, 255, 0.92);
    backdrop-filter: blur(20px) saturate(180%);
    -webkit-backdrop-filter: blur(20px) saturate(180%);
    border-radius: 20px;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.18),
        0 0 0 1px rgba(255, 107, 107, 0.15),
        0 0 24px rgba(255, 107, 107, 0.25);
    overflow: hidden;
    position: relative;
    animation: chatNotifyPulseGlow 2s ease-in-out infinite;
}
@keyframes chatNotifyPulseGlow {
    0%, 100% {
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.18),
            0 0 0 1px rgba(255, 107, 107, 0.15),
            0 0 24px rgba(255, 107, 107, 0.25);
    }
    50% {
        box-shadow:
            0 8px 32px rgba(0, 0, 0, 0.22),
            0 0 0 2px rgba(255, 107, 107, 0.4),
            0 0 40px rgba(255, 107, 107, 0.45),
            0 0 80px rgba(255, 107, 107, 0.15);
    }
}
.chat-notify-accent {
    height: 4px;
    background: linear-gradient(90deg, var(--coral), #ff8a65, var(--coral));
    background-size: 200% 100%;
    animation: chatNotifyAccentShift 1.5s ease infinite;
}
@keyframes chatNotifyAccentShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}
.chat-notify-content {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 14px 16px 10px;
}
.chat-notify-photo {
    width: 52px;
    height: 52px;
    border-radius: 50%;
    border: 3px solid var(--coral);
    object-fit: cover;
    flex-shrink: 0;
    box-shadow: 0 2px 12px rgba(255, 107, 107, 0.3);
}
.chat-notify-text {
    flex: 1;
    min-width: 0;
}
.chat-notify-name {
    font-size: 16px;
    font-weight: 800;
    color: var(--text-primary);
    margin-bottom: 3px;
}
.chat-notify-preview {
    font-size: 14px;
    color: var(--slate);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 240px;
}
.chat-notify-actions {
    display: flex;
    gap: 8px;
    padding: 6px 16px 14px;
}
.chat-notify-btn {
    flex: 1;
    padding: 10px 12px;
    font-size: 14px;
    font-weight: 700;
    border: none;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.1s, opacity 0.15s;
    touch-action: manipulation;
}
.chat-notify-btn:active {
    transform: scale(0.96);
}
.chat-notify-btn-reply {
    background: var(--coral);
    color: white;
    box-shadow: 0 2px 8px rgba(255, 107, 107, 0.35);
}
.chat-notify-btn-dismiss {
    background: var(--light-gray);
    color: var(--slate);
}

@media (max-width: 380px) {
    .chat-notify-overlay {
        padding: 8px 10px;
    }
    .chat-notify-card {
        border-radius: 16px;
    }
    .chat-notify-photo {
        width: 44px;
        height: 44px;
    }
    .chat-notify-name {
        font-size: 15px;
    }
    .chat-notify-preview {
        font-size: 13px;
        max-width: 180px;
    }
}

