* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --wa-dark-bg: #0b141a;
    --wa-chat-bg: #0b141a;
    --wa-header-bg: #202c33;
    --wa-input-bg: #2a3942;
    --wa-outgoing: #005c4b;
    --wa-incoming: #202c33;
    --wa-text: #e9edef;
    --wa-text-secondary: #8696a0;
    --wa-green: #00a884;
    --wa-green-light: #25d366;
    --wa-border: #222d34;
    --wa-timestamp: #8696a0;
    --wa-link: #53bdeb;
    --wa-highlight: #ffc107;
}

html, body {
    height: 100%;
    overflow: hidden;
}

/* Lock Screen */
.lock-screen {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(135deg, #0b141a 0%, #1a2e38 50%, #0b141a 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    padding: 20px;
}

.lock-screen.hidden {
    display: none;
}

.lock-content {
    background: linear-gradient(145deg, #1f2c34 0%, #121b22 100%);
    border-radius: 24px;
    padding: 40px 30px;
    max-width: 350px;
    width: 100%;
    text-align: center;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: lockAppear 0.5s ease;
}

@keyframes lockAppear {
    from {
        opacity: 0;
        transform: scale(0.9) translateY(20px);
    }
    to {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.lock-icon {
    font-size: 60px;
    margin-bottom: 20px;
    animation: lockPulse 2s infinite;
}

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

.lock-title {
    font-size: 24px;
    color: var(--wa-text);
    margin-bottom: 8px;
    font-weight: 600;
}

.lock-subtitle {
    font-size: 14px;
    color: #ff6b9d;
    margin-bottom: 30px;
    font-style: italic;
}

.lock-input-container {
    margin-bottom: 20px;
}

.lock-input {
    width: 100%;
    padding: 16px 20px;
    font-size: 24px;
    letter-spacing: 8px;
    text-align: center;
    background: var(--wa-input-bg);
    border: 2px solid transparent;
    border-radius: 16px;
    color: var(--wa-text);
    outline: none;
    transition: all 0.3s ease;
}

.lock-input:focus {
    border-color: var(--wa-green);
    box-shadow: 0 0 20px rgba(0, 168, 132, 0.2);
}

.lock-input::placeholder {
    color: var(--wa-text-secondary);
    letter-spacing: 4px;
}

.lock-hint {
    font-size: 13px;
    color: var(--wa-text-secondary);
    margin-bottom: 24px;
    line-height: 1.5;
}

.lock-btn {
    width: 100%;
    padding: 16px;
    background: linear-gradient(135deg, #ff6b9d 0%, #c44569 100%);
    color: white;
    border: none;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 20px rgba(255, 107, 157, 0.3);
}

.lock-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 25px rgba(255, 107, 157, 0.4);
}

.lock-btn:active {
    transform: translateY(0);
}

.lock-error {
    margin-top: 16px;
    font-size: 13px;
    color: #ff4757;
    min-height: 20px;
}

.lock-footer {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 105, 180, 0.2);
}

.lock-server-msg {
    color: rgba(255, 255, 255, 0.6);
    font-size: 12px;
    margin: 6px 0;
    font-style: italic;
}

.lock-server-msg .port-number {
    color: #ff69b4;
    font-weight: 600;
    font-style: normal;
    background: rgba(255, 105, 180, 0.15);
    padding: 2px 8px;
    border-radius: 4px;
}

.lock-server-msg.small {
    font-size: 11px;
    margin-top: 12px;
    color: rgba(255, 255, 255, 0.4);
}

.lock-input.shake {
    animation: shake 0.5s ease;
    border-color: #ff4757;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-10px); }
    40%, 80% { transform: translateX(10px); }
}

@keyframes fadeOut {
    from {
        opacity: 1;
        transform: scale(1);
    }
    to {
        opacity: 0;
        transform: scale(1.1);
    }
}

/* Loading more indicator */
.loading-more {
    text-align: center;
    padding: 15px;
    color: var(--wa-text-secondary);
    font-size: 13px;
}

body {
    font-family: 'Segoe UI', -apple-system, BlinkMacSystemFont, sans-serif;
    background: var(--wa-dark-bg);
    color: var(--wa-text);
}

.whatsapp-container {
    display: flex;
    flex-direction: column;
    height: 100%;
    max-width: 100%;
    margin: 0 auto;
    position: relative;
    overflow: hidden;
}

/* Desktop view */
@media (min-width: 768px) {
    body {
        background: #111b21;
        display: flex;
        justify-content: center;
        align-items: center;
        padding: 20px;
    }
    
    .whatsapp-container {
        max-width: 450px;
        height: 90vh;
        max-height: 900px;
        border-radius: 12px;
        overflow: hidden;
        box-shadow: 0 10px 60px rgba(0, 0, 0, 0.5);
    }
}

/* Header */
.chat-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 6px;
    background: var(--wa-header-bg);
    min-height: 60px;
    z-index: 100;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 2px;
    flex: 1;
    min-width: 0;
}

.back-btn {
    background: none;
    border: none;
    color: var(--wa-text-secondary);
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
}

.back-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.profile-section {
    display: flex;
    align-items: center;
    gap: 12px;
    flex: 1;
    min-width: 0;
    cursor: pointer;
}

.avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.avatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.contact-info {
    flex: 1;
    min-width: 0;
}

.contact-name {
    font-size: 16px;
    font-weight: 500;
    color: var(--wa-text);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.contact-status {
    font-size: 12px;
    color: var(--wa-text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.header-actions {
    display: flex;
    gap: 4px;
}

.action-btn {
    background: none;
    border: none;
    color: var(--wa-text-secondary);
    padding: 8px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
}

.action-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

/* Search Bar */
.search-bar {
    display: none;
    align-items: center;
    padding: 8px;
    background: var(--wa-header-bg);
    gap: 8px;
    border-bottom: 1px solid var(--wa-border);
}

.search-bar.active {
    display: flex;
}

.search-input-container {
    flex: 1;
    display: flex;
    align-items: center;
    background: var(--wa-input-bg);
    border-radius: 8px;
    padding: 4px;
}

.search-back-btn {
    background: none;
    border: none;
    color: var(--wa-text-secondary);
    padding: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

#search-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--wa-text);
    font-size: 15px;
    padding: 8px;
    outline: none;
}

#search-input::placeholder {
    color: var(--wa-text-secondary);
}

.search-nav {
    display: flex;
    align-items: center;
    gap: 4px;
}

#search-count {
    font-size: 12px;
    color: var(--wa-text-secondary);
    min-width: 50px;
    text-align: center;
}

.search-nav-btn {
    background: none;
    border: none;
    color: var(--wa-text-secondary);
    padding: 6px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background 0.2s;
}

.search-nav-btn:hover {
    background: rgba(255, 255, 255, 0.1);
}

.search-nav-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

/* Search highlight */
.search-highlight {
    background: var(--wa-highlight);
    color: #000;
    padding: 1px 2px;
    border-radius: 2px;
}

.search-highlight.current {
    background: #ff9800;
}

.message.search-active {
    animation: pulse-highlight 0.5s ease;
}

@keyframes pulse-highlight {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.02); box-shadow: 0 0 20px rgba(0, 168, 132, 0.5); }
}

/* Profile Modal */
.profile-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    z-index: 1000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.profile-modal.active {
    display: flex;
    opacity: 1;
}

.profile-modal-content {
    background: var(--wa-header-bg);
    border-radius: 16px;
    width: 100%;
    max-width: 360px;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(30px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.profile-header-bg {
    height: 100px;
    background: linear-gradient(135deg, var(--wa-green) 0%, #128C7E 100%);
    border-radius: 16px 16px 0 0;
}

.profile-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(0, 0, 0, 0.3);
    border: none;
    color: white;
    padding: 8px;
    cursor: pointer;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
}

.profile-close:hover {
    background: rgba(0, 0, 0, 0.5);
}

.profile-avatar-large {
    width: 120px;
    height: 120px;
    border-radius: 50%;
    overflow: hidden;
    margin: -60px auto 16px;
    border: 4px solid var(--wa-header-bg);
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.3);
}

.profile-avatar-large img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.profile-name {
    text-align: center;
    font-size: 24px;
    font-weight: 600;
    color: var(--wa-text);
    margin-bottom: 4px;
}

.profile-title {
    text-align: center;
    font-size: 14px;
    color: var(--wa-green-light);
    margin-bottom: 4px;
    padding: 0 20px;
}

.profile-realname {
    text-align: center;
    font-size: 13px;
    color: #ff6b9d;
    margin-bottom: 16px;
    font-style: italic;
}

.profile-section-card {
    padding: 16px 20px;
    border-bottom: 1px solid var(--wa-border);
}

.profile-label {
    font-size: 12px;
    color: var(--wa-green);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.profile-about {
    font-size: 15px;
    color: var(--wa-text);
}

.profile-status-text {
    font-size: 14px;
    color: var(--wa-text-secondary);
    font-style: italic;
    line-height: 1.5;
}

.profile-note {
    font-size: 14px;
    color: var(--wa-text);
    line-height: 1.5;
}

.heart-icon {
    margin-right: 6px;
}

.profile-stats {
    display: flex;
    justify-content: space-around;
    padding: 20px;
    text-align: center;
}

.stat {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.stat-value {
    font-size: 24px;
    font-weight: 600;
    color: var(--wa-green-light);
}

.stat-label {
    font-size: 12px;
    color: var(--wa-text-secondary);
}

/* Chat Container */
.chat-container {
    flex: 1;
    overflow: hidden;
    position: relative;
    background: var(--wa-chat-bg);
}

.chat-bg {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0.06;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    pointer-events: none;
}

.messages {
    height: 100%;
    overflow-y: auto;
    padding: 8px 16px;
    display: flex;
    flex-direction: column;
    gap: 2px;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.messages::-webkit-scrollbar {
    width: 6px;
}

.messages::-webkit-scrollbar-track {
    background: transparent;
}

.messages::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 3px;
}

/* Message Bubbles */
.message {
    max-width: 85%;
    padding: 6px 7px 8px 9px;
    border-radius: 7.5px;
    position: relative;
    word-wrap: break-word;
    animation: messageIn 0.3s ease;
    margin-top: 2px;
}

/* Gap between sent and received messages */
.message.sent + .message.received,
.message.received + .message.sent {
    margin-top: 10px;
}

@keyframes messageIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.message.sent {
    background: var(--wa-outgoing);
    align-self: flex-end;
    border-top-right-radius: 0;
}

.message.sent::before {
    content: '';
    position: absolute;
    top: 0;
    right: -8px;
    border-width: 0 0 8px 8px;
    border-style: solid;
    border-color: transparent transparent transparent var(--wa-outgoing);
}

.message.received {
    background: var(--wa-incoming);
    align-self: flex-start;
    border-top-left-radius: 0;
}

.message.received::before {
    content: '';
    position: absolute;
    top: 0;
    left: -8px;
    border-width: 0 8px 8px 0;
    border-style: solid;
    border-color: transparent var(--wa-incoming) transparent transparent;
}

.message-content {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    gap: 4px;
}

.message-text {
    font-size: 14.2px;
    line-height: 19px;
    color: var(--wa-text);
    white-space: pre-wrap;
    flex: 1;
    min-width: 0;
}

.message-text a {
    color: var(--wa-link);
    text-decoration: none;
}

.message-text a:hover {
    text-decoration: underline;
}

.message-meta {
    display: flex;
    align-items: center;
    gap: 3px;
    margin-left: auto;
    flex-shrink: 0;
}

.message-time {
    font-size: 11px;
    color: rgba(255, 255, 255, 0.6);
    white-space: nowrap;
}

.message-status {
    display: flex;
    align-items: center;
}

.message-status svg {
    width: 16px;
    height: 16px;
    color: #53bdeb;
}

/* Date Separator */
.date-separator {
    display: flex;
    justify-content: center;
    padding: 10px 0;
}

.date-badge {
    background: #1d282f;
    color: var(--wa-text-secondary);
    padding: 5px 12px;
    border-radius: 7.5px;
    font-size: 12.5px;
    box-shadow: 0 1px 0.5px rgba(11, 20, 26, 0.13);
}

/* System Messages */
.system-message {
    text-align: center;
    padding: 8px 16px;
}

.system-message span {
    background: #1d282f;
    color: #e1c879;
    padding: 5px 12px;
    border-radius: 7.5px;
    font-size: 12.5px;
    display: inline-block;
    max-width: 90%;
}

/* Footer */
.chat-footer {
    display: flex;
    align-items: center;
    padding: 6px 8px;
    gap: 8px;
    background: var(--wa-header-bg);
}

.input-container {
    flex: 1;
    display: flex;
    align-items: center;
    background: var(--wa-input-bg);
    border-radius: 8px;
    padding: 6px 8px;
    gap: 8px;
}

.emoji-btn,
.attach-btn {
    background: none;
    border: none;
    color: var(--wa-text-secondary);
    padding: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.message-input {
    flex: 1;
    background: none;
    border: none;
    color: var(--wa-text);
    font-size: 15px;
    outline: none;
    min-width: 0;
}

.message-input::placeholder {
    color: var(--wa-text-secondary);
}

.mic-btn {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--wa-green);
    border: none;
    color: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    transition: transform 0.2s;
}

.mic-btn:hover {
    transform: scale(1.05);
}

/* Scroll to bottom button */
.scroll-bottom {
    position: absolute;
    bottom: 80px;
    right: 16px;
    width: 42px;
    height: 42px;
    border-radius: 50%;
    background: var(--wa-header-bg);
    border: none;
    color: var(--wa-text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
    z-index: 50;
    transition: transform 0.2s, opacity 0.2s;
}

.scroll-bottom:hover {
    transform: scale(1.1);
}

/* Loading */
.loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    height: 100%;
    gap: 16px;
    color: var(--wa-text-secondary);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 3px solid var(--wa-border);
    border-top-color: var(--wa-green);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

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

/* Image messages */
.message-image {
    max-width: 100%;
    border-radius: 6px;
    margin-bottom: 4px;
    cursor: pointer;
}

/* Emoji-only messages */
.message.emoji-only {
    background: transparent !important;
    padding: 4px;
}

.message.emoji-only::before {
    display: none;
}

.message.emoji-only .message-text {
    font-size: 48px;
    line-height: 1.2;
}

/* Consecutive messages */
.message.consecutive {
    margin-top: -1px;
}

.message.sent.consecutive {
    border-top-right-radius: 7.5px;
}

.message.sent.consecutive::before {
    display: none;
}

.message.received.consecutive {
    border-top-left-radius: 7.5px;
}

.message.received.consecutive::before {
    display: none;
}

/* Deleted message */
.message.deleted .message-text {
    color: var(--wa-text-secondary);
    font-style: italic;
}

/* Edited indicator */
.edited-indicator {
    font-size: 10px;
    color: rgba(255, 255, 255, 0.45);
    margin-right: 4px;
}

/* Media placeholder */
.message.media-placeholder .message-text {
    color: rgba(255, 255, 255, 0.7);
    font-style: italic;
}

/* Safe area for notched phones */
@supports (padding-top: env(safe-area-inset-top)) {
    .chat-header {
        padding-top: calc(10px + env(safe-area-inset-top));
    }
    
    .chat-footer {
        padding-bottom: calc(6px + env(safe-area-inset-bottom));
    }
}

/* Touch feedback */
@media (hover: none) {
    .action-btn:active,
    .back-btn:active {
        background: rgba(255, 255, 255, 0.1);
    }
}

/* Reduce motion */
@media (prefers-reduced-motion: reduce) {
    .message {
        animation: none;
    }
    
    .loading-spinner {
        animation: none;
    }
}

/* Special Card in Profile */
.special-card {
    background: linear-gradient(135deg, rgba(37, 211, 102, 0.1) 0%, rgba(18, 140, 126, 0.1) 100%);
    border: 1px solid rgba(37, 211, 102, 0.2);
    border-radius: 12px;
    margin: 16px;
    padding: 16px !important;
}

.special-quote {
    font-size: 14px;
    color: var(--wa-text);
    line-height: 1.8;
    text-align: center;
    font-style: italic;
}

.profile-footer {
    text-align: center;
    padding: 16px;
    color: var(--wa-text-secondary);
    font-size: 12px;
    border-top: 1px solid var(--wa-border);
}

/* Love Modal (Back Button) */
.love-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.love-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.love-modal-content {
    background: linear-gradient(145deg, #1a2c38 0%, #0d1b24 100%);
    border-radius: 24px;
    padding: 32px 24px;
    text-align: center;
    max-width: 340px;
    width: 100%;
    border: 1px solid rgba(37, 211, 102, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
                0 0 40px rgba(37, 211, 102, 0.1);
    animation: popIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes popIn {
    from {
        transform: scale(0.8);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

.love-hearts {
    font-size: 48px;
    margin-bottom: 16px;
    animation: heartbeat 1.5s ease-in-out infinite;
}

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

.love-title {
    font-size: 22px;
    color: var(--wa-text);
    margin-bottom: 12px;
    font-weight: 600;
}

.love-message {
    font-size: 18px;
    color: var(--wa-green-light);
    margin-bottom: 4px;
    font-weight: 500;
}

.love-submessage {
    font-size: 16px;
    color: #ff6b9d;
    margin-bottom: 20px;
}

.love-poetry {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 24px;
    font-size: 14px;
    color: var(--wa-text-secondary);
    line-height: 1.8;
    font-style: italic;
    border-left: 3px solid var(--wa-green);
}

.love-stay-btn {
    background: linear-gradient(135deg, var(--wa-green) 0%, #128C7E 100%);
    color: white;
    border: none;
    padding: 14px 32px;
    border-radius: 30px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.love-stay-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.love-stay-btn:active {
    transform: translateY(0);
}

.love-footer {
    margin-top: 20px;
    font-size: 12px;
    color: var(--wa-text-secondary);
    font-style: italic;
}

/* Menu Dropdown */
.menu-dropdown {
    position: absolute;
    top: 55px;
    right: 8px;
    background: var(--wa-header-bg);
    border-radius: 12px;
    min-width: 220px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.4);
    z-index: 500;
    display: none;
    overflow: hidden;
    border: 1px solid var(--wa-border);
    animation: menuSlide 0.2s ease;
}

@keyframes menuSlide {
    from {
        opacity: 0;
        transform: translateY(-10px) scale(0.95);
    }
    to {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.menu-dropdown.active {
    display: block;
}

.menu-header {
    padding: 14px 16px;
    font-size: 13px;
    color: var(--wa-green-light);
    font-weight: 600;
    text-align: center;
    background: linear-gradient(135deg, rgba(37, 211, 102, 0.1) 0%, rgba(18, 140, 126, 0.1) 100%);
    border-bottom: 1px solid var(--wa-border);
}

.menu-item {
    display: flex;
    align-items: center;
    padding: 12px 16px;
    cursor: pointer;
    transition: background 0.2s;
    gap: 12px;
}

.menu-item:hover {
    background: rgba(255, 255, 255, 0.05);
}

.menu-item:active {
    background: rgba(255, 255, 255, 0.1);
}

.menu-icon {
    font-size: 18px;
    width: 24px;
    text-align: center;
}

.menu-item span:nth-child(2) {
    flex: 1;
    font-size: 14px;
    color: var(--wa-text);
}

.menu-hint {
    font-size: 11px;
    color: var(--wa-text-secondary);
}

.menu-divider {
    height: 1px;
    background: var(--wa-border);
    margin: 4px 0;
}

/* Special Secret Letter Menu Item */
.menu-item.special-item {
    background: linear-gradient(135deg, rgba(255, 105, 180, 0.15), rgba(255, 20, 147, 0.1));
    border: 1px solid rgba(255, 105, 180, 0.3);
    border-radius: 12px;
    margin: 8px 8px 4px 8px;
    padding: 14px 16px;
    position: relative;
    overflow: hidden;
}

.menu-item.special-item::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(45deg, transparent, rgba(255, 105, 180, 0.1), transparent);
    animation: shimmer 3s infinite;
}

@keyframes shimmer {
    0% { transform: translateX(-50%) rotate(45deg); }
    100% { transform: translateX(50%) rotate(45deg); }
}

.menu-item.special-item:hover {
    background: linear-gradient(135deg, rgba(255, 105, 180, 0.25), rgba(255, 20, 147, 0.2));
    transform: scale(1.02);
}

.menu-icon.glow {
    animation: glow 2s ease-in-out infinite;
    font-size: 22px;
}

@keyframes glow {
    0%, 100% { filter: drop-shadow(0 0 3px #ff69b4); transform: scale(1); }
    50% { filter: drop-shadow(0 0 10px #ff1493); transform: scale(1.1); }
}

.special-text {
    font-weight: 600;
    background: linear-gradient(90deg, #ff69b4, #ff1493, #ff69b4);
    background-size: 200% auto;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradient-text 3s linear infinite;
}

@keyframes gradient-text {
    0% { background-position: 0% center; }
    100% { background-position: 200% center; }
}

.menu-hint.special-hint {
    color: #ff69b4;
    font-weight: 500;
}

/* Stats Modal */
.stats-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.9);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 20px;
}

.stats-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.stats-modal-content {
    background: linear-gradient(145deg, #1a2c38 0%, #0d1b24 100%);
    border-radius: 20px;
    padding: 24px;
    max-width: 380px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    position: relative;
    border: 1px solid rgba(37, 211, 102, 0.2);
    animation: popIn 0.4s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

.modal-close {
    position: absolute;
    top: 12px;
    right: 12px;
    background: rgba(255, 255, 255, 0.1);
    border: none;
    color: var(--wa-text-secondary);
    width: 32px;
    height: 32px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 16px;
    transition: all 0.2s;
}

.modal-close:hover {
    background: rgba(255, 255, 255, 0.2);
    color: var(--wa-text);
}

.stats-title {
    text-align: center;
    font-size: 22px;
    color: var(--wa-text);
    margin-bottom: 4px;
}

.stats-subtitle {
    text-align: center;
    font-size: 13px;
    color: var(--wa-text-secondary);
    margin-bottom: 24px;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.stat-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 16px;
    text-align: center;
    border: 1px solid rgba(255, 255, 255, 0.05);
    transition: transform 0.2s;
}

.stat-card:hover {
    transform: scale(1.02);
}

.stat-emoji {
    font-size: 24px;
    display: block;
    margin-bottom: 8px;
}

.stat-number {
    font-size: 28px;
    font-weight: 700;
    color: var(--wa-green-light);
    display: block;
}

.stat-text {
    font-size: 11px;
    color: var(--wa-text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.stats-footer {
    text-align: center;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--wa-border);
}

.stats-footer p {
    font-size: 13px;
    color: var(--wa-text-secondary);
    font-style: italic;
}

/* Secret Love Letter Modal */
.secret-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.95);
    z-index: 2000;
    display: none;
    justify-content: center;
    align-items: center;
    padding: 16px;
}

.secret-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.secret-modal-content {
    background: linear-gradient(145deg, #2d1f3d 0%, #1a1225 100%);
    border-radius: 24px;
    padding: 28px 24px;
    max-width: 380px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    text-align: center;
    border: 1px solid rgba(255, 107, 157, 0.3);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5),
                0 0 40px rgba(255, 107, 157, 0.1);
    animation: letterOpen 0.6s cubic-bezier(0.68, -0.55, 0.265, 1.55);
}

@keyframes letterOpen {
    from {
        transform: scale(0.5) rotateX(90deg);
        opacity: 0;
    }
    to {
        transform: scale(1) rotateX(0);
        opacity: 1;
    }
}

.secret-envelope {
    font-size: 56px;
    margin-bottom: 12px;
    animation: float 3s ease-in-out infinite;
}

@keyframes float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

.secret-title {
    font-size: 22px;
    color: #ff6b9d;
    margin-bottom: 4px;
    font-weight: 600;
}

.secret-subtitle {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.5);
    margin-bottom: 20px;
    font-style: italic;
}

.secret-letter {
    background: rgba(255, 255, 255, 0.03);
    border-radius: 16px;
    padding: 20px;
    text-align: left;
    border: 1px solid rgba(255, 255, 255, 0.05);
    margin-bottom: 20px;
}

.letter-greeting {
    font-size: 16px;
    color: #ff6b9d;
    margin-bottom: 16px;
    font-weight: 500;
}

.letter-body {
    font-size: 14px;
    color: var(--wa-text);
    line-height: 1.7;
    margin-bottom: 14px;
}

.letter-closing {
    font-size: 14px;
    color: var(--wa-text);
    margin-top: 20px;
    text-align: right;
}

.letter-signature {
    font-size: 18px;
    color: #ff6b9d;
    font-weight: 600;
    font-style: italic;
}

.secret-close-btn {
    background: linear-gradient(135deg, #ff6b9d 0%, #c44569 100%);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.3);
}

.secret-close-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 157, 0.4);
}

/* Message highlight animation */
@keyframes highlight {
    0% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0.7);
    }
    30% {
        box-shadow: 0 0 20px 10px rgba(37, 211, 102, 0.4);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(37, 211, 102, 0);
    }
}

/* Emoji Modal */
.emoji-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.emoji-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.emoji-modal-content {
    background: linear-gradient(145deg, #1f2c34 0%, #121b22 100%);
    border-radius: 24px;
    padding: 28px 24px;
    max-width: 350px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.emoji-title {
    font-size: 20px;
    color: #ffd700;
    margin-bottom: 8px;
}

.emoji-subtitle {
    font-size: 13px;
    color: var(--wa-text-secondary);
    margin-bottom: 20px;
}

.emoji-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    margin-bottom: 20px;
}

.emoji-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 12px 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 6px;
}

.big-emoji {
    font-size: 32px;
}

.emoji-meaning {
    font-size: 10px;
    color: var(--wa-text-secondary);
}

.emoji-footer {
    font-size: 12px;
    color: #ff6b9d;
    font-style: italic;
}

/* Giant Eyes Container */
.eyes-container {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 30px 0;
}

.giant-eyes {
    font-size: 100px;
    animation: eyeBlink 3s infinite;
}

@keyframes eyeBlink {
    0%, 90%, 100% { opacity: 1; transform: scale(1); }
    95% { opacity: 0.5; transform: scale(0.95); }
}

.eyes-poetry {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
    font-style: italic;
    color: #ff6b9d;
    font-size: 14px;
    line-height: 1.8;
}

.eyes-poetry p {
    margin: 4px 0;
}

/* Attachment Modal */
.attach-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.8);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.attach-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.attach-modal-content {
    background: linear-gradient(145deg, #1f2c34 0%, #121b22 100%);
    border-radius: 24px;
    padding: 28px 24px;
    max-width: 350px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.attach-title {
    font-size: 20px;
    color: #25d366;
    margin-bottom: 8px;
}

.attach-subtitle {
    font-size: 13px;
    color: var(--wa-text-secondary);
    margin-bottom: 20px;
}

.memory-cards {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin-bottom: 20px;
}

.memory-card {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 14px;
    display: flex;
    align-items: center;
    gap: 12px;
    text-align: left;
}

.memory-icon {
    font-size: 28px;
}

.memory-text {
    flex: 1;
    font-size: 14px;
    color: var(--wa-text);
    font-weight: 500;
}

.memory-date {
    font-size: 11px;
    color: #25d366;
}

.memory-section {
    margin-bottom: 20px;
}

.memory-heading {
    font-size: 14px;
    color: #ff6b9d;
    margin-bottom: 10px;
    text-align: left;
    padding-left: 4px;
}

.memory-section .memory-cards {
    margin-bottom: 0;
}

.attach-footer {
    font-size: 12px;
    color: var(--wa-text-secondary);
    font-style: italic;
    margin-top: 10px;
}

/* Mic Modal */
.mic-modal {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.85);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    padding: 20px;
}

.mic-modal.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

.mic-modal-content {
    background: linear-gradient(145deg, #2d1f3d 0%, #1a1225 100%);
    border-radius: 24px;
    padding: 32px 24px;
    max-width: 350px;
    width: 100%;
    text-align: center;
    position: relative;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
}

.mic-animation {
    font-size: 60px;
    margin-bottom: 16px;
    animation: pulse 1.5s infinite;
}

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

.mic-title {
    font-size: 20px;
    color: #ff6b9d;
    margin-bottom: 16px;
}

/* Song Player */
.song-player {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 16px;
    padding: 20px;
    margin-bottom: 20px;
}

.song-info {
    display: flex;
    flex-direction: column;
    gap: 4px;
    margin-bottom: 16px;
}

.song-name {
    font-size: 16px;
    color: var(--wa-text);
    font-weight: 600;
}

.song-artist {
    font-size: 12px;
    color: var(--wa-text-secondary);
}

.audio-controls {
    display: flex;
    justify-content: center;
}

.play-btn {
    background: linear-gradient(135deg, #25d366 0%, #128c7e 100%);
    color: white;
    border: none;
    padding: 12px 32px;
    border-radius: 25px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(37, 211, 102, 0.3);
}

.play-btn:hover {
    transform: scale(1.05);
    box-shadow: 0 6px 20px rgba(37, 211, 102, 0.4);
}

.play-btn:disabled {
    background: linear-gradient(135deg, #666 0%, #444 100%);
    cursor: not-allowed;
    box-shadow: none;
}

.song-status {
    margin-top: 12px;
    font-size: 12px;
    color: var(--wa-text-secondary);
}

.mic-message {
    font-size: 15px;
    color: var(--wa-text);
    margin-bottom: 12px;
    font-style: italic;
}

.mic-submessage {
    font-size: 13px;
    color: var(--wa-text-secondary);
    margin-bottom: 16px;
    line-height: 1.6;
}

.mic-quote {
    background: rgba(255, 255, 255, 0.05);
    border-radius: 12px;
    padding: 14px;
    font-size: 14px;
    color: var(--wa-green-light);
    margin-bottom: 20px;
    border-left: 3px solid #ff6b9d;
}

.mic-close-btn {
    background: linear-gradient(135deg, #ff6b9d 0%, #c44569 100%);
    color: white;
    border: none;
    padding: 14px 28px;
    border-radius: 30px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.3);
}

.mic-close-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 157, 0.4);
}

/* ========== First Time Walkthrough ========== */
.walkthrough-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 9999;
    pointer-events: none; /* Allow clicks to pass through by default */
}

.walkthrough-overlay:not(.hidden) {
    pointer-events: auto; /* Capture clicks when active */
}

.walkthrough-overlay .walkthrough-tooltip {
    pointer-events: auto; /* Tooltip always captures clicks */
}

.walkthrough-overlay.hidden {
    display: none;
}

.walkthrough-backdrop {
    display: none; /* Spotlight box-shadow handles the overlay */
}

.walkthrough-spotlight {
    position: fixed;
    border-radius: 50%;
    border: 5px solid #ff69b4;
    box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5);
    transition: all 0.4s ease;
    pointer-events: none;
    z-index: 10000;
    background: transparent;
    animation: spotlight-glow 1.5s ease-in-out infinite;
}

@keyframes spotlight-glow {
    0%, 100% { border-color: #ff69b4; border-width: 5px; }
    50% { border-color: #ff1493; border-width: 7px; }
}

/* Direct highlight on target element */
.walkthrough-highlight {
    position: relative;
    z-index: 9999 !important;
    outline: 4px solid #ff69b4 !important;
    outline-offset: 4px !important;
    animation: element-pulse 1.5s ease-in-out infinite !important;
}

@keyframes element-pulse {
    0%, 100% { outline-color: #ff69b4; outline-offset: 4px; }
    50% { outline-color: #ff1493; outline-offset: 6px; }
}

@keyframes spotlight-pulse {
    0%, 100% { box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5), 0 0 0 4px #ff69b4, 0 0 15px #ff69b4; }
    50% { box-shadow: 0 0 0 9999px rgba(0, 0, 0, 0.5), 0 0 0 4px #ff1493, 0 0 30px #ff1493; }
}

.walkthrough-tooltip {
    position: fixed;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 2px solid #ff69b4;
    border-radius: 16px;
    padding: 16px 20px;
    max-width: 280px;
    width: calc(100% - 40px);
    box-shadow: 0 10px 40px rgba(255, 105, 180, 0.3);
    animation: tooltip-bounce 0.5s ease;
    z-index: 10000;
}

@media (max-width: 480px) {
    .walkthrough-tooltip {
        max-width: calc(100vw - 40px);
        left: 20px !important;
        right: 20px !important;
        padding: 14px 16px;
    }
    
    .walkthrough-text {
        font-size: 14px;
    }
}

@keyframes tooltip-bounce {
    0% { opacity: 0; transform: translateY(20px); }
    100% { opacity: 1; transform: translateY(0); }
}

.walkthrough-arrow {
    position: absolute;
    width: 0;
    height: 0;
    border-left: 12px solid transparent;
    border-right: 12px solid transparent;
    border-bottom: 12px solid #ff69b4;
    top: -12px;
    left: 50%;
    transform: translateX(-50%);
}

.walkthrough-tooltip.arrow-bottom .walkthrough-arrow {
    top: auto;
    bottom: -12px;
    border-bottom: none;
    border-top: 12px solid #ff69b4;
}

.walkthrough-tooltip.arrow-left .walkthrough-arrow {
    top: 50%;
    left: -12px;
    transform: translateY(-50%);
    border-bottom: 12px solid transparent;
    border-top: 12px solid transparent;
    border-left: none;
    border-right: 12px solid #ff69b4;
}

.walkthrough-tooltip.arrow-right .walkthrough-arrow {
    top: 50%;
    left: auto;
    right: -12px;
    transform: translateY(-50%);
    border-bottom: 12px solid transparent;
    border-top: 12px solid transparent;
    border-right: none;
    border-left: 12px solid #ff69b4;
}

.walkthrough-text {
    color: #fff;
    font-size: 16px;
    line-height: 1.6;
    margin: 0 0 16px 0;
    text-align: center;
}

.walkthrough-text .highlight {
    color: #ff69b4;
    font-weight: 600;
}

/* Intro tooltip - centered with special styling */
.walkthrough-tooltip.intro-tooltip {
    background: linear-gradient(135deg, #2d1f3d 0%, #1a1a2e 100%);
    border: 3px solid #ff69b4;
    box-shadow: 0 0 60px rgba(255, 105, 180, 0.4);
    animation: intro-pulse 2s ease-in-out infinite, tooltip-bounce 0.5s ease;
}

.walkthrough-tooltip.intro-tooltip .walkthrough-arrow {
    display: none;
}

@keyframes intro-pulse {
    0%, 100% { box-shadow: 0 0 40px rgba(255, 105, 180, 0.3); }
    50% { box-shadow: 0 0 60px rgba(255, 105, 180, 0.5); }
}

.walkthrough-buttons {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.walkthrough-step {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
}

.walkthrough-next {
    background: linear-gradient(135deg, #ff69b4, #ff1493);
    color: white;
    border: none;
    padding: 10px 24px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
}

.walkthrough-next:hover {
    transform: scale(1.05);
    box-shadow: 0 4px 15px rgba(255, 105, 180, 0.4);
}

.walkthrough-skip {
    color: rgba(255, 255, 255, 0.5);
    font-size: 12px;
    cursor: pointer;
    background: none;
    border: none;
    margin-right: 10px;
}

.walkthrough-skip:hover {
    color: #ff69b4;
}

/* Cache Loader Overlay */
.cache-loader {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9000;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 2px solid #ff69b4;
    border-radius: 16px;
    padding: 16px 24px;
    box-shadow: 0 10px 40px rgba(255, 105, 180, 0.3);
    animation: cache-slide-up 0.4s ease;
    max-width: 300px;
    width: 90%;
}

.cache-loader.hidden {
    display: none;
}

@keyframes cache-slide-up {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.cache-loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.cache-heart {
    font-size: 28px;
    animation: cache-pulse 1s ease-in-out infinite;
}

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

.cache-text {
    color: #fff;
    font-size: 14px;
    text-align: center;
    margin: 0;
}

.cache-progress {
    width: 100%;
    height: 6px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 3px;
    overflow: hidden;
}

.cache-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #ff69b4, #ff1493);
    border-radius: 3px;
    transition: width 0.3s ease;
    animation: cache-shimmer 1.5s ease-in-out infinite;
}

@keyframes cache-shimmer {
    0% { background-position: -200% 0; }
    100% { background-position: 200% 0; }
}

/* ===== Bottom Chat Loader (Same style as Cache Loader) ===== */
.chat-loader {
    position: fixed;
    bottom: 80px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 9999;
    background: linear-gradient(135deg, #1a1a2e 0%, #16213e 100%);
    border: 2px solid #ff69b4;
    border-radius: 16px;
    padding: 16px 24px;
    box-shadow: 0 10px 40px rgba(255, 105, 180, 0.3);
    animation: chat-loader-slide-up 0.4s ease;
    max-width: 300px;
    width: 90%;
}

.chat-loader.hidden {
    display: none;
}

@keyframes chat-loader-slide-up {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.chat-loader-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.chat-loader-heart {
    font-size: 28px;
    animation: chat-heart-pulse 1s ease-in-out infinite;
}

@keyframes chat-heart-pulse {
    0%, 100% { transform: scale(1); }
    50% { transform: scale(1.2); }
}

.chat-loader-text-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.chat-loader-text {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    text-align: center;
    margin: 0;
}

.chat-loader-subtext {
    color: #ff69b4;
    font-size: 12px;
    font-style: italic;
    text-align: center;
    margin: 0;
}

/* Hide dots - not needed for this style */
.chat-loader-dots {
    display: none;
}

/* ============================================
   BLUR MODE - For non-authenticated users
   ============================================ */

/* Blur message text */
body.blur-mode .message-text,
body.blur-mode .message-content {
    filter: blur(6px);
    user-select: none;
    pointer-events: none;
}

/* Blur attachments/media */
body.blur-mode .message-media,
body.blur-mode .message-image,
body.blur-mode .message-video,
body.blur-mode .message-audio,
body.blur-mode audio,
body.blur-mode video,
body.blur-mode img:not(.profile-pic):not(.header-icon) {
    filter: blur(12px);
    pointer-events: none;
}

/* Don't blur header except profile pic */
body.blur-mode .chat-header {
    filter: none !important;
}

/* Blur profile pic for friends */
body.blur-mode .chat-header .avatar img,
body.blur-mode #profile-pic {
    filter: blur(8px) !important;
}

/* Hide attachment/memories modal for friends (secured) */
body.blur-mode .attach-modal.active {
    display: none !important;
}

body.blur-mode .attach-modal-content {
    filter: blur(8px) !important;
    user-select: none;
    pointer-events: none;
}

/* Verify overlay - Floating card for friends */
.verify-overlay {
    position: fixed;
    bottom: 100px;
    left: 50%;
    transform: translateX(-50%);
    z-index: 1000;
    animation: floatUp 0.6s ease-out;
    pointer-events: none;
    width: auto;
    max-width: 90%;
}

.verify-overlay * {
    pointer-events: auto;
}

@keyframes floatUp {
    from {
        opacity: 0;
        transform: translateX(-50%) translateY(50px);
    }
    to {
        opacity: 1;
        transform: translateX(-50%) translateY(0);
    }
}

.verify-box {
    background: linear-gradient(135deg, rgba(20, 20, 35, 0.98) 0%, rgba(40, 20, 50, 0.98) 100%);
    border: 2px solid rgba(255, 107, 157, 0.5);
    border-radius: 20px;
    padding: 16px 24px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 12px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6), 0 0 20px rgba(255, 107, 157, 0.2);
    backdrop-filter: blur(15px);
    text-align: center;
}

.verify-box .heart {
    font-size: 36px;
    animation: heartbeat 1.5s ease-in-out infinite;
    flex-shrink: 0;
}

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

.verify-box h3 {
    color: #ff6b9d;
    font-size: 18px;
    margin: 0;
    font-weight: 700;
    letter-spacing: 0.5px;
}

.verify-box p {
    color: #aaa;
    font-size: 13px;
    margin: 0;
}

.verify-btn {
    display: inline-block;
    padding: 12px 28px;
    background: linear-gradient(135deg, #ff6b9d 0%, #c44569 100%);
    color: white;
    text-decoration: none;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    flex-shrink: 0;
    margin-top: 5px;
    box-shadow: 0 4px 15px rgba(255, 107, 157, 0.4);
}

.verify-btn:hover {
    transform: translateY(-2px) scale(1.02);
    box-shadow: 0 6px 25px rgba(255, 107, 157, 0.5);
}

.verify-btn:active {
    transform: scale(0.98);
}

/* Mobile adjustments - center it well */
@media (max-width: 600px) {
    .verify-overlay {
        bottom: 90px;
        left: 50%;
        right: auto;
        transform: translateX(-50%);
        width: calc(100% - 30px);
        max-width: 320px;
    }
    
    .verify-box {
        padding: 18px 20px;
        border-radius: 16px;
    }
    
    .verify-box .heart {
        font-size: 32px;
    }
    
    .verify-box h3 {
        font-size: 16px;
    }
    
    .verify-box p {
        font-size: 12px;
    }
    
    .verify-btn {
        padding: 12px 24px;
        font-size: 13px;
        width: 100%;
    }
}
