/* ============================================================
   HUSHBOX - COMPLETE STYLES (ALL UPDATES)
   ============================================================ */

/* ===== ROOT VARIABLES ===== */
:root {
    --bg: #f4f6fc;
    --card: #ffffff;
    --text: #0b0b1a;
    --text-secondary: #4b4b66;
    --border: #e2e6f0;
    --primary: #6c5ce7;
    --primary-soft: #a29bfe;
    --shadow: 0 12px 40px rgba(0, 0, 0, 0.06);
    --radius: 24px;
    --radius-sm: 14px;
    --transition: 0.3s cubic-bezier(0.2, 0.9, 0.4, 1);
    --nav-width: 280px;
}

[data-theme="dark"] {
    --bg: #0d0d1a;
    --card: #18182e;
    --text: #f0f0f8;
    --text-secondary: #b0b0c8;
    --border: #2f2f48;
    --shadow: 0 12px 40px rgba(0, 0, 0, 0.6);
}

/* ===== RESET & BASE ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

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

body {
    font-family: 'Inter', -apple-system, system-ui, sans-serif;
    background: var(--bg);
    color: var(--text);
    transition: background 0.4s, color 0.4s;
}

.app-wrapper {
    max-width: 100%;
    width: 100%;
    height: 100vh;
    background: var(--card);
    position: relative;
    overflow: hidden;
    transition: background 0.4s;
    display: flex;
    flex-direction: column;
}

/* ===== SPLASH ===== */
.splash {
    position: fixed;
    inset: 0;
    z-index: 999;
    background: linear-gradient(145deg, #0f0b2a 0%, #1b103a 40%, #0d1b2a 80%);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 24px;
    transition: opacity 0.7s ease, transform 0.7s ease;
    pointer-events: none;
}

.splash.hide {
    opacity: 0;
    transform: scale(0.96);
    pointer-events: none;
}

.splash-ring {
    position: absolute;
    border-radius: 50%;
    border: 1.5px solid rgba(108, 92, 231, 0.15);
    animation: pulseRing 5s infinite alternate;
}

.splash-ring.r1 {
    width: 200px;
    height: 200px;
    top: 10%;
    left: 8%;
}

.splash-ring.r2 {
    width: 320px;
    height: 320px;
    bottom: 6%;
    right: 4%;
    animation-delay: 1.8s;
}

.splash-ring.r3 {
    width: 440px;
    height: 440px;
    top: 16%;
    right: 8%;
    animation-delay: 3.2s;
    border-color: rgba(162, 155, 254, 0.07);
}

@keyframes pulseRing {
    0% {
        transform: scale(0.94);
        opacity: 0.3;
    }
    100% {
        transform: scale(1.1);
        opacity: 0.05;
    }
}

.splash-icon {
    width: 74px;
    height: 74px;
    border-radius: 50%;
    background: rgba(108, 92, 231, 0.2);
    padding: 14px;
    border: 2px solid rgba(162, 155, 254, 0.3);
    animation: floatIcon 3s ease-in-out infinite;
    margin-bottom: 4px;
}

.splash-icon img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: contain;
}

@keyframes floatIcon {
    0%,
    100% {
        transform: translateY(0) scale(1);
    }
    50% {
        transform: translateY(-12px) scale(1.04);
    }
}

.splash-title {
    font-size: 2.6rem;
    font-weight: 800;
    background: linear-gradient(135deg, #a29bfe, #6c5ce7, #a29bfe);
    background-size: 200% 200%;
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    animation: gradShift 3.6s ease infinite;
    letter-spacing: -0.5px;
}

.splash-title span {
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

@keyframes gradShift {
    0%,
    100% {
        background-position: 0% 50%;
    }
    50% {
        background-position: 100% 50%;
    }
}

.splash-tag {
    color: rgba(255, 255, 255, 0.5);
    font-weight: 300;
    letter-spacing: 1.5px;
    font-size: 0.9rem;
}

.splash-progress {
    width: 180px;
    height: 3px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 20px;
    margin: 24px auto 10px;
    overflow: hidden;
}

.splash-progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #6c5ce7, #a29bfe);
    border-radius: 20px;
    transition: width 0.06s linear;
}

.splash-bubbles {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 14px;
    margin: 14px 0 6px;
}

.splash-bubble {
    background: rgba(255, 255, 255, 0.04);
    backdrop-filter: blur(6px);
    padding: 4px 14px;
    border-radius: 40px;
    font-size: 0.7rem;
    color: rgba(255, 255, 255, 0.6);
    border: 1px solid rgba(255, 255, 255, 0.04);
    animation: floatBubble 4.5s infinite alternate;
    white-space: nowrap;
}

.splash-bubble:nth-child(2) {
    animation-delay: 1s;
}
.splash-bubble:nth-child(3) {
    animation-delay: 2s;
}
.splash-bubble:nth-child(4) {
    animation-delay: 0.6s;
}
.splash-bubble:nth-child(5) {
    animation-delay: 2.8s;
}

@keyframes floatBubble {
    0% {
        transform: translateY(0);
        opacity: 0.5;
    }
    100% {
        transform: translateY(-6px);
        opacity: 1;
    }
}

.splash-powered {
    color: rgba(255, 255, 255, 0.25);
    font-size: 0.65rem;
    margin-top: 14px;
    letter-spacing: 0.3px;
}

.splash-powered strong {
    color: rgba(255, 255, 255, 0.5);
}

/* ===== HEADER ===== */
.app-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 16px;
    border-bottom: 1px solid var(--border);
    background: var(--card);
    flex-shrink: 0;
    z-index: 99;
    position: sticky;
    top: 0;
    min-height: 56px;
}

.header-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.header-logo {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    object-fit: contain;
}

.header-left h1 {
    font-size: 1.1rem;
    font-weight: 700;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.header-right {
    display: flex;
    align-items: center;
    gap: 8px;
}

.premium-badge {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    color: #0b0b1a;
    font-size: 0.5rem;
    font-weight: 800;
    padding: 2px 10px;
    border-radius: 40px;
    letter-spacing: 0.4px;
    display: none;
}

.premium-badge.show {
    display: inline-block;
    animation: glowBadge 2.4s infinite alternate;
}

@keyframes glowBadge {
    0% {
        box-shadow: 0 0 4px rgba(251, 191, 36, 0.2);
    }
    100% {
        box-shadow: 0 0 18px rgba(251, 191, 36, 0.6);
    }
}

.theme-toggle {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 50%;
    width: 34px;
    height: 34px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: var(--transition);
}

.theme-toggle:hover {
    transform: rotate(20deg);
}

.avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #fff;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
}

.avatar:hover {
    transform: scale(1.06);
}

/* ===== NAV RAIL TOGGLE ===== */
.nav-rail-toggle {
    background: var(--bg);
    border: 1px solid var(--border);
    border-radius: 8px;
    width: 36px;
    height: 36px;
    cursor: pointer;
    font-size: 1.2rem;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--text);
}

.nav-rail-toggle:hover {
    background: var(--border);
}

/* ===== NAV RAIL ===== */
.nav-rail-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    z-index: 200;
    display: none;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.nav-rail-overlay.open {
    display: block;
    opacity: 1;
}

.nav-rail {
    position: fixed;
    top: 0;
    right: -100%;
    width: var(--nav-width);
    max-width: 85%;
    height: 100vh;
    background: var(--card);
    z-index: 201;
    transition: right 0.35s cubic-bezier(0.2, 0.9, 0.4, 1);
    box-shadow: -4px 0 30px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
    padding: 20px 0;
}

.nav-rail.open {
    right: 0;
}

.nav-rail-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 20px 16px;
    border-bottom: 1px solid var(--border);
    margin-bottom: 12px;
}

.nav-rail-header .rail-logo {
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 700;
    font-size: 1.1rem;
}

.nav-rail-header .rail-logo img {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    object-fit: contain;
}

.nav-rail-close {
    background: none;
    border: none;
    font-size: 1.4rem;
    cursor: pointer;
    color: var(--text-secondary);
    transition: var(--transition);
}

.nav-rail-close:hover {
    transform: rotate(90deg);
}

.nav-rail-items {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 0 12px;
    flex: 1;
    overflow-y: auto;
}

.nav-rail-item {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 12px 16px;
    border-radius: var(--radius-sm);
    text-decoration: none;
    color: var(--text-secondary);
    transition: var(--transition);
    cursor: pointer;
    font-weight: 500;
    font-size: 0.95rem;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
}

.nav-rail-item:hover {
    background: var(--bg);
    color: var(--text);
    transform: translateX(4px);
}

.nav-rail-item.active {
    background: rgba(108, 92, 231, 0.1);
    color: var(--primary);
    font-weight: 700;
    border-right: 3px solid var(--primary);
}

.nav-rail-item .nav-icon {
    font-size: 1.3rem;
    width: 28px;
    text-align: center;
    flex-shrink: 0;
}

.nav-rail-item .nav-badge {
    margin-left: auto;
    background: var(--primary);
    color: #fff;
    font-size: 0.65rem;
    padding: 2px 8px;
    border-radius: 40px;
    font-weight: 600;
}

.nav-rail-footer {
    padding: 16px 20px 0;
    border-top: 1px solid var(--border);
    margin-top: auto;
}

.nav-rail-footer .user-info {
    display: flex;
    align-items: center;
    gap: 12px;
}

.nav-rail-footer .user-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1rem;
    color: #fff;
}

.nav-rail-footer .user-name {
    font-weight: 600;
    font-size: 0.9rem;
}

.nav-rail-footer .user-email {
    font-size: 0.75rem;
    color: var(--text-secondary);
}

/* ===== CONTENT ===== */
.main-content {
    display: flex;
    flex-direction: column;
    flex: 1;
    overflow: hidden;
    min-height: 0;
}

.content {
    padding: 12px 16px;
    overflow-y: auto;
    flex: 1;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 80px;
    height: 100%;
}

.content::-webkit-scrollbar {
    width: 4px;
}

.content::-webkit-scrollbar-track {
    background: var(--bg);
}

.content::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

/* ===== COMPOSER ===== */
.composer {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 14px;
    margin-bottom: 14px;
    transition: var(--transition);
}

.composer:hover {
    box-shadow: var(--shadow);
}

.composer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 6px;
}

.composer-title {
    font-weight: 600;
    font-size: 0.95rem;
}

.composer textarea {
    width: 100%;
    min-height: 70px;
    padding: 10px 12px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--card);
    color: var(--text);
    font-size: 0.9rem;
    resize: vertical;
    transition: var(--transition);
    font-family: inherit;
}

.composer textarea:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.08);
    outline: none;
}

.composer input {
    width: 100%;
    padding: 8px 12px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--card);
    color: var(--text);
    font-size: 0.85rem;
    margin-bottom: 6px;
    transition: var(--transition);
}

.composer input:focus {
    border-color: var(--primary);
    outline: none;
}

.composer-actions {
    display: flex;
    gap: 6px;
    margin-top: 6px;
}

.composer-actions .btn-primary {
    flex: 1;
    padding: 10px;
    font-size: 0.9rem;
}

.composer-actions .btn-secondary {
    flex: 0.5;
    padding: 10px;
    font-size: 0.85rem;
}

.char-count {
    font-size: 0.7rem;
    color: var(--text-secondary);
}

.message-limit {
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-align: right;
    margin-top: 4px;
}

/* ===== BUTTONS ===== */
.btn-primary {
    background: linear-gradient(135deg, #6c5ce7, #8b7cf7);
    border: none;
    padding: 14px;
    border-radius: var(--radius-sm);
    font-weight: 700;
    color: #fff;
    transition: var(--transition);
    cursor: pointer;
    width: 100%;
    font-size: 1rem;
}

.btn-primary:hover {
    transform: scale(1.02) translateY(-2px);
    box-shadow: 0 12px 28px rgba(108, 92, 231, 0.3);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none !important;
}

.btn-primary.btn-sm {
    padding: 6px 12px;
    width: auto;
    font-size: 0.7rem;
}

.btn-secondary {
    background: var(--bg);
    border: 2px solid var(--border);
    padding: 12px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    color: var(--text);
    transition: var(--transition);
    cursor: pointer;
    width: 100%;
}

.btn-secondary:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.btn-secondary.btn-sm {
    padding: 6px 12px;
    width: auto;
    font-size: 0.7rem;
}

.btn-danger {
    padding: 12px;
    border: none;
    border-radius: var(--radius-sm);
    font-size: 0.95rem;
    font-weight: 600;
    cursor: pointer;
    transition: var(--transition);
    background: #e74c3c;
    color: #fff;
    width: 100%;
    margin-top: 8px;
}

.btn-danger:hover {
    background: #c0392b;
    transform: translateY(-2px);
}

.btn-danger.btn-sm {
    padding: 6px 12px;
    width: auto;
    font-size: 0.7rem;
}

.btn-danger.delete-btn {
    background: #c0392b;
}

/* ===== MESSAGES ===== */
.messages-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.messages-title {
    font-weight: 600;
    font-size: 0.95rem;
}

.message-item {
    background: var(--bg);
    padding: 12px 14px;
    border-radius: var(--radius-sm);
    border-left: 4px solid var(--primary);
    margin-bottom: 8px;
    transition: var(--transition);
    cursor: pointer;
    animation: slideUp 0.35s ease forwards;
    opacity: 0;
    transform: translateY(12px);
}

.message-item-actions {
    display: flex;
    gap: 6px;
    margin-top: 6px;
    flex-wrap: wrap;
}

.message-item-actions button {
    background: none;
    border: none;
    font-size: 0.7rem;
    color: var(--text-secondary);
    cursor: pointer;
    padding: 4px 10px;
    border-radius: 4px;
    transition: var(--transition);
}

.message-item-actions button:hover {
    background: var(--border);
    color: var(--text);
}

.message-item-actions .reply-btn {
    color: var(--primary);
}

.message-item-actions .reply-btn:hover {
    background: rgba(108, 92, 231, 0.1);
}

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

.message-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow);
}

.message-item .title {
    font-weight: 600;
    font-size: 0.9rem;
}

.message-item .body {
    font-size: 0.8rem;
    color: var(--text-secondary);
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.message-item .meta {
    display: flex;
    justify-content: space-between;
    font-size: 0.6rem;
    color: var(--text-secondary);
    margin-top: 4px;
}

.empty-state {
    text-align: center;
    padding: 30px 10px;
    color: var(--text-secondary);
}

.empty-icon {
    font-size: 2.4rem;
    display: block;
    margin-bottom: 6px;
}

/* ===== AD POPUP ===== */
.ad-popup {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    margin-bottom: 12px;
    animation: slideDown 0.4s ease;
    border: 2px solid #f59e0b;
}

.ad-popup .ad-content {
    display: flex;
    align-items: center;
    gap: 10px;
    color: #0b0b1a;
}

.ad-popup .ad-icon {
    font-size: 1.5rem;
}

.ad-popup .ad-text h4 {
    font-weight: 700;
    font-size: 0.85rem;
}

.ad-popup .ad-text p {
    font-size: 0.75rem;
    opacity: 0.8;
}

.ad-popup .ad-close {
    background: rgba(0, 0, 0, 0.1);
    border: none;
    color: #0b0b1a;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.8rem;
    margin-left: auto;
    transition: var(--transition);
}

.ad-popup .ad-close:hover {
    background: rgba(0, 0, 0, 0.2);
}

/* ===== AD ENGINE STYLES ===== */
#hushboxAdContainer {
    position: fixed;
    bottom: 24px;
    right: 24px;
    width: 360px;
    height: 202px;
    z-index: 9998;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 8px 40px rgba(0,0,0,0.5);
    transform: translateX(120%) scale(0.9);
    opacity: 0;
    transition: all 0.5s cubic-bezier(0.34, 1.56, 0.64, 1);
    cursor: pointer;
    background: #000;
    border: 2px solid rgba(255,255,255,0.1);
    pointer-events: none;
}

#hushboxAdContainer.showing {
    pointer-events: auto;
}

#hushboxAdContainer:hover {
    transform: scale(1.02) !important;
    box-shadow: 0 12px 50px rgba(0,0,0,0.6) !important;
    border-color: rgba(108,92,231,0.3) !important;
}

#hushboxAdProgressBar {
    box-shadow: 0 0 10px rgba(108,92,231,0.3);
}

#hushboxAdClose {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0,0,0,0.7);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.15);
    color: #fff;
    width: 30px;
    height: 30px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 0.8rem;
    z-index: 4;
    opacity: 0;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Inter', sans-serif;
    pointer-events: none;
    transform: scale(0.8);
}

#hushboxAdClose:hover {
    background: rgba(231,76,60,0.8) !important;
    transform: scale(1.1) !important;
}

#hushboxAdBanner {
    position: absolute;
    top: 10px;
    left: 10px;
    background: rgba(0,0,0,0.75);
    backdrop-filter: blur(10px);
    padding: 5px 14px;
    border-radius: 20px;
    color: #fff;
    font-size: 0.65rem;
    font-weight: 500;
    z-index: 3;
    font-family: 'Inter', -apple-system, system-ui, sans-serif;
    display: flex;
    align-items: center;
    gap: 8px;
    border: 1px solid rgba(255,255,255,0.1);
    pointer-events: none;
}

#hushboxAdSound {
    position: absolute;
    top: 10px;
    right: 50px;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(10px);
    padding: 3px 10px;
    border-radius: 12px;
    color: #4ade80;
    font-size: 0.55rem;
    z-index: 3;
    font-family: 'Inter', sans-serif;
    border: 1px solid rgba(74,222,128,0.2);
    display: flex;
    align-items: center;
    gap: 4px;
    pointer-events: none;
    opacity: 0;
    transition: opacity 0.5s ease;
}

#hushboxAdTime {
    position: absolute;
    bottom: 8px;
    right: 12px;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(10px);
    padding: 2px 8px;
    border-radius: 10px;
    color: rgba(255,255,255,0.7);
    font-size: 0.55rem;
    z-index: 3;
    font-family: 'Inter', sans-serif;
    font-weight: 500;
    pointer-events: none;
}

@media (max-width: 480px) {
    #hushboxAdContainer {
        width: 280px !important;
        height: 158px !important;
        bottom: 10px !important;
        right: 10px !important;
        border-radius: 12px !important;
    }
    
    #hushboxAdBanner {
        font-size: 0.55rem !important;
        padding: 3px 10px !important;
    }
    
    #hushboxAdClose {
        width: 24px !important;
        height: 24px !important;
        font-size: 0.7rem !important;
        top: 6px !important;
        right: 6px !important;
    }

    #hushboxAdSound {
        font-size: 0.5rem !important;
        padding: 2px 8px !important;
        right: 40px !important;
        top: 6px !important;
    }
}

@media (max-width: 380px) {
    #hushboxAdContainer {
        width: 220px !important;
        height: 124px !important;
        bottom: 8px !important;
        right: 8px !important;
        border-radius: 10px !important;
    }
}

/* ===== ENHANCED HUSH MODAL ===== */
.hush-modal-enhanced {
    padding: 0 !important;
    max-width: 480px !important;
    border-radius: 24px !important;
    overflow: hidden !important;
    background: var(--card) !important;
    animation: modalSlideIn 0.4s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
}

@keyframes modalSlideIn {
    0% {
        opacity: 0;
        transform: translateY(40px) scale(0.92);
    }
    100% {
        opacity: 1;
        transform: translateY(0) scale(1);
    }
}

.hush-modal-close {
    position: absolute !important;
    top: 12px !important;
    right: 14px !important;
    z-index: 10 !important;
    color: #fff !important;
    font-size: 1.2rem !important;
    background: rgba(255,255,255,0.15) !important;
    width: 32px !important;
    height: 32px !important;
    border-radius: 50% !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    transition: all 0.3s ease !important;
    backdrop-filter: blur(10px) !important;
    border: 1px solid rgba(255,255,255,0.1) !important;
}

.hush-modal-close:hover {
    background: rgba(255,255,255,0.3) !important;
    transform: rotate(90deg) scale(1.1) !important;
}

/* Enhanced Header */
.hush-enhanced-header {
    background: linear-gradient(135deg, #6c5ce7, #a29bfe) !important;
    padding: 20px 24px !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    position: relative !important;
    overflow: hidden !important;
}

.hush-enhanced-header::before {
    content: '' !important;
    position: absolute !important;
    top: -50% !important;
    right: -20% !important;
    width: 60% !important;
    height: 200% !important;
    background: rgba(255,255,255,0.05) !important;
    border-radius: 50% !important;
    pointer-events: none !important;
}

.hush-header-left {
    display: flex !important;
    align-items: center !important;
    gap: 12px !important;
    position: relative !important;
    z-index: 1 !important;
}

.hush-avatar-ring {
    width: 44px !important;
    height: 44px !important;
    border-radius: 50% !important;
    background: rgba(255,255,255,0.2) !important;
    padding: 4px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    border: 2px solid rgba(255,255,255,0.3) !important;
}

.hush-header-avatar {
    width: 100% !important;
    height: 100% !important;
    border-radius: 50% !important;
    object-fit: contain !important;
}

.hush-header-title {
    color: #fff !important;
    font-weight: 700 !important;
    font-size: 1.1rem !important;
}

.hush-header-badge {
    background: rgba(255,255,255,0.2) !important;
    padding: 2px 12px !important;
    border-radius: 20px !important;
    font-size: 0.6rem !important;
    font-weight: 600 !important;
    color: #fff !important;
    display: inline-block !important;
    margin-top: 2px !important;
    letter-spacing: 0.3px !important;
}

.hush-header-right {
    position: relative !important;
    z-index: 1 !important;
}

.hush-header-sender {
    color: rgba(255,255,255,0.9) !important;
    font-size: 0.75rem !important;
    font-weight: 500 !important;
    background: rgba(0,0,0,0.2) !important;
    padding: 4px 12px !important;
    border-radius: 20px !important;
    backdrop-filter: blur(5px) !important;
}

/* Enhanced Body */
.hush-enhanced-body {
    padding: 20px 24px 16px !important;
    background: var(--card) !important;
}

.hush-message-card {
    display: flex !important;
    gap: 14px !important;
    background: var(--bg) !important;
    border-radius: 16px !important;
    padding: 16px !important;
    margin-bottom: 14px !important;
    border: 1px solid var(--border) !important;
    transition: all 0.3s ease !important;
}

.hush-message-card:hover {
    transform: translateY(-2px) !important;
    box-shadow: 0 8px 25px rgba(0,0,0,0.05) !important;
}

.hush-message-icon {
    font-size: 1.5rem !important;
    flex-shrink: 0 !important;
    width: 40px !important;
    height: 40px !important;
    background: rgba(108,92,231,0.1) !important;
    border-radius: 12px !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.hush-message-content {
    flex: 1 !important;
    min-width: 0 !important;
}

.hush-enhanced-title {
    font-size: 1rem !important;
    font-weight: 700 !important;
    color: var(--text) !important;
    margin: 0 0 4px 0 !important;
}

.hush-enhanced-message {
    font-size: 0.9rem !important;
    color: var(--text-secondary) !important;
    line-height: 1.6 !important;
    margin: 0 !important;
    word-break: break-word !important;
}

/* Enhanced Meta */
.hush-enhanced-meta {
    display: flex !important;
    gap: 20px !important;
    padding: 8px 0 !important;
    margin-bottom: 12px !important;
}

.hush-meta-item {
    display: flex !important;
    align-items: center !important;
    gap: 6px !important;
    font-size: 0.7rem !important;
    color: var(--text-secondary) !important;
}

.hush-meta-icon {
    font-size: 0.8rem !important;
}

.hush-meta-text {
    font-weight: 500 !important;
}

/* Enhanced Replies */
.hush-replies-enhanced {
    background: var(--bg) !important;
    border-radius: 16px !important;
    padding: 14px !important;
    border: 1px solid var(--border) !important;
}

.hush-replies-header {
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
    font-size: 0.8rem !important;
    font-weight: 600 !important;
    color: var(--text-secondary) !important;
    margin-bottom: 10px !important;
}

.hush-replies-count {
    background: var(--card) !important;
    padding: 2px 10px !important;
    border-radius: 20px !important;
    font-size: 0.65rem !important;
    color: var(--primary) !important;
}

.hush-replies-list {
    max-height: 120px !important;
    overflow-y: auto !important;
    margin-bottom: 10px !important;
}

.hush-replies-list::-webkit-scrollbar {
    width: 3px !important;
}

.hush-replies-list::-webkit-scrollbar-thumb {
    background: var(--primary) !important;
    border-radius: 10px !important;
}

.hush-reply-input-wrapper {
    display: flex !important;
    gap: 8px !important;
}

.hush-reply-input {
    flex: 1 !important;
    padding: 10px 14px !important;
    border: 2px solid var(--border) !important;
    border-radius: 12px !important;
    background: var(--card) !important;
    color: var(--text) !important;
    font-size: 0.85rem !important;
    transition: all 0.3s ease !important;
    font-family: inherit !important;
}

.hush-reply-input:focus {
    border-color: var(--primary) !important;
    outline: none !important;
    box-shadow: 0 0 0 3px rgba(108,92,231,0.1) !important;
}

.hush-reply-send-btn {
    padding: 10px 14px !important;
    border: none !important;
    border-radius: 12px !important;
    background: linear-gradient(135deg, #6c5ce7, #8b7cf7) !important;
    color: #fff !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
}

.hush-reply-send-btn:hover {
    transform: scale(1.05) !important;
    box-shadow: 0 8px 20px rgba(108,92,231,0.3) !important;
}

.hush-reply-send-btn svg {
    stroke: #fff !important;
}

/* Enhanced Footer */
.hush-enhanced-footer {
    padding: 16px 24px 20px !important;
    background: var(--bg) !important;
    border-top: 1px solid var(--border) !important;
}

.hush-share-section {
    margin-bottom: 12px !important;
}

.hush-share-label {
    font-size: 0.7rem !important;
    color: var(--text-secondary) !important;
    font-weight: 600 !important;
    text-align: center !important;
    margin-bottom: 8px !important;
}

.hush-share-buttons {
    display: flex !important;
    justify-content: center !important;
    gap: 10px !important;
}

.hush-share-btn {
    width: 36px !important;
    height: 36px !important;
    border-radius: 50% !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-decoration: none !important;
    background: var(--card) !important;
    border: 1px solid var(--border) !important;
}

.hush-share-btn:hover {
    transform: scale(1.12) translateY(-3px) !important;
    box-shadow: 0 8px 20px rgba(0,0,0,0.1) !important;
}

.hush-share-btn.social-fb {
    background: #1877F2 !important;
    border-color: #1877F2 !important;
}
.hush-share-btn.social-tw {
    background: #000 !important;
    border-color: #000 !important;
}
.hush-share-btn.social-ig {
    background: #E4405F !important;
    border-color: #E4405F !important;
}
.hush-share-btn.social-wa {
    background: #25D366 !important;
    border-color: #25D366 !important;
}
.hush-share-btn.social-li {
    background: #0A66C2 !important;
    border-color: #0A66C2 !important;
}

.hush-share-btn svg {
    fill: #fff !important;
}

/* Action Row with QR Button */
.hush-actions-row {
    display: flex !important;
    gap: 8px !important;
}

.hush-action-btn {
    flex: 1 !important;
    padding: 10px !important;
    border: none !important;
    border-radius: 12px !important;
    font-weight: 600 !important;
    font-size: 0.8rem !important;
    cursor: pointer !important;
    transition: all 0.3s ease !important;
    font-family: inherit !important;
    text-align: center !important;
    white-space: nowrap !important;
}

.hush-action-btn:hover {
    transform: translateY(-2px) !important;
}

.share-link-btn {
    background: var(--card) !important;
    color: var(--text) !important;
    border: 2px solid var(--border) !important;
}

.share-link-btn:hover {
    border-color: var(--primary) !important;
    background: rgba(108,92,231,0.05) !important;
}

/* QR Code Button - Green Gradient */
.share-qr-btn {
    background: linear-gradient(135deg, #10b981, #34d399) !important;
    color: #fff !important;
    border: none !important;
}

.share-qr-btn:hover {
    box-shadow: 0 8px 25px rgba(16, 185, 129, 0.3) !important;
}

.share-save-btn {
    background: linear-gradient(135deg, #6c5ce7, #8b7cf7) !important;
    color: #fff !important;
}

.share-save-btn:hover {
    box-shadow: 0 8px 25px rgba(108,92,231,0.3) !important;
}

.share-edit-btn {
    background: #fbbf24 !important;
    color: #0b0b1a !important;
}

.share-edit-btn:hover {
    box-shadow: 0 8px 25px rgba(251,191,36,0.3) !important;
}

/* Reply items in enhanced modal */
.hush-replies-list .reply-item {
    padding: 8px 12px !important;
    background: var(--card) !important;
    border-radius: 10px !important;
    margin-bottom: 6px !important;
    font-size: 0.8rem !important;
    border: 1px solid var(--border) !important;
    display: flex !important;
    justify-content: space-between !important;
    align-items: center !important;
}

.hush-replies-list .reply-item .reply-body {
    flex: 1 !important;
    margin: 0 8px !important;
    word-break: break-word !important;
}

.hush-replies-list .reply-item .reply-sender {
    font-weight: 600 !important;
    color: var(--primary) !important;
    font-size: 0.7rem !important;
}

.hush-replies-list .reply-item .reply-date {
    font-size: 0.6rem !important;
    color: var(--text-secondary) !important;
    flex-shrink: 0 !important;
}

.reply-empty {
    text-align: center !important;
    color: var(--text-secondary) !important;
    font-size: 0.8rem !important;
    padding: 16px 0 !important;
    margin: 0 !important;
}

/* Dark theme adjustments for enhanced modal */
[data-theme="dark"] .hush-message-card {
    background: rgba(255,255,255,0.03) !important;
}

[data-theme="dark"] .hush-replies-enhanced {
    background: rgba(255,255,255,0.03) !important;
}

[data-theme="dark"] .hush-enhanced-footer {
    background: rgba(255,255,255,0.02) !important;
}

/* ===== QR CODE MODAL STYLES ===== */
#qrCodeContainer {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%) scale(0.9);
    z-index: 10000;
    background: var(--card, #ffffff);
    border-radius: 24px;
    padding: 32px;
    box-shadow: 0 20px 60px rgba(0,0,0,0.3);
    max-width: 420px;
    width: 90%;
    opacity: 0;
    pointer-events: none;
    transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1);
    border: 1px solid var(--border, #e2e6f0);
}

#qrCodeContainer.active {
    opacity: 1;
    pointer-events: auto;
    transform: translate(-50%, -50%) scale(1);
}

[data-theme="dark"] #qrCodeContainer {
    background: #18182e;
    border-color: #2f2f48;
}

.qr-close-btn {
    position: absolute;
    top: 12px;
    right: 12px;
    background: var(--bg, #f4f6fc);
    border: none;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.3s ease;
    color: var(--text-secondary, #4b4b66);
}

.qr-close-btn:hover {
    background: rgba(231, 76, 60, 0.1);
    color: #e74c3c;
    transform: rotate(90deg);
}

[data-theme="dark"] .qr-close-btn {
    background: #2f2f48;
    color: #b0b0c8;
}

.qr-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 20px;
}

.qr-header-icon {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    color: #fff;
    flex-shrink: 0;
}

.qr-title {
    font-size: 1.1rem;
    font-weight: 700;
    color: var(--text, #0b0b1a);
    margin: 0;
}

.qr-subtitle {
    font-size: 0.8rem;
    color: var(--text-secondary, #4b4b66);
    margin: 2px 0 0;
}

[data-theme="dark"] .qr-title {
    color: #f0f0f8;
}

.qr-code-wrapper {
    position: relative;
    background: var(--bg, #f4f6fc);
    border-radius: 16px;
    padding: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    border: 2px solid var(--border, #e2e6f0);
    min-height: 220px;
    transition: all 0.3s ease;
}

[data-theme="dark"] .qr-code-wrapper {
    background: #0d0d1a;
    border-color: #2f2f48;
}

.qr-code-wrapper:hover {
    border-color: var(--primary, #6c5ce7);
}

.qr-code-display {
    display: flex;
    align-items: center;
    justify-content: center;
    min-height: 200px;
}

.qr-code-display img,
.qr-code-display canvas {
    border-radius: 8px;
    max-width: 100%;
    height: auto;
}

.qr-brand-overlay {
    position: absolute;
    bottom: 30px;
    right: 30px;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: var(--card, #ffffff);
    padding: 6px;
    box-shadow: 0 2px 12px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid var(--border, #e2e6f0);
}

[data-theme="dark"] .qr-brand-overlay {
    background: #18182e;
    border-color: #2f2f48;
}

.qr-brand-logo {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: contain;
}

.qr-message {
    display: flex;
    align-items: center;
    gap: 10px;
    background: rgba(108, 92, 231, 0.05);
    border-radius: 12px;
    padding: 10px 14px;
    margin-bottom: 16px;
    border: 1px solid rgba(108, 92, 231, 0.1);
}

.qr-message-icon {
    font-size: 1.2rem;
}

.qr-message-text {
    font-size: 0.85rem;
    color: var(--text-secondary, #4b4b66);
    font-weight: 500;
}

[data-theme="dark"] .qr-message {
    background: rgba(108, 92, 231, 0.08);
}

[data-theme="dark"] .qr-message-text {
    color: #b0b0c8;
}

.qr-footer {
    display: flex;
    gap: 10px;
    margin-bottom: 12px;
}

.qr-download-btn,
.qr-share-btn {
    flex: 1;
    padding: 12px;
    border: none;
    border-radius: 12px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    font-family: 'Inter', sans-serif;
}

.qr-download-btn {
    background: linear-gradient(135deg, #6c5ce7, #8b7cf7);
    color: #fff;
}

.qr-download-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.3);
}

.qr-share-btn {
    background: var(--bg, #f4f6fc);
    color: var(--text, #0b0b1a);
    border: 2px solid var(--border, #e2e6f0);
}

.qr-share-btn:hover {
    border-color: var(--primary, #6c5ce7);
    transform: translateY(-2px);
}

[data-theme="dark"] .qr-share-btn {
    background: #2f2f48;
    color: #f0f0f8;
    border-color: #2f2f48;
}

[data-theme="dark"] .qr-share-btn:hover {
    border-color: #6c5ce7;
}

.qr-download-btn svg,
.qr-share-btn svg {
    stroke: currentColor;
    flex-shrink: 0;
}

.qr-download-btn svg {
    stroke: #fff;
}

.qr-share-btn svg {
    stroke: var(--text, #0b0b1a);
}

[data-theme="dark"] .qr-share-btn svg {
    stroke: #f0f0f8;
}

.qr-powered {
    text-align: center;
    font-size: 0.65rem;
    color: var(--text-secondary, #4b4b66);
}

.qr-powered strong {
    color: var(--primary, #6c5ce7);
    font-weight: 700;
}

[data-theme="dark"] .qr-powered {
    color: #b0b0c8;
}

.qr-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
    padding: 20px;
}

.qr-loading-spinner {
    width: 36px;
    height: 36px;
    border: 3px solid var(--border, #e2e6f0);
    border-top-color: var(--primary, #6c5ce7);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
}

.qr-loading-text {
    font-size: 0.8rem;
    color: var(--text-secondary, #4b4b66);
}

.qr-overlay-bg {
    position: fixed;
    inset: 0;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(8px);
    z-index: 9999;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.4s ease;
}

.qr-overlay-bg.active {
    opacity: 1;
    pointer-events: auto;
}

/* ===== INBOX STYLES ===== */
.inbox-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

.inbox-header h2 {
    font-size: 1.1rem;
    font-weight: 700;
}

.inbox-count {
    background: var(--bg);
    padding: 4px 14px;
    border-radius: 40px;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--primary);
}

.inbox-item {
    background: var(--bg);
    padding: 14px 16px;
    border-radius: var(--radius-sm);
    margin-bottom: 12px;
    transition: all 0.3s ease;
    border-left: 4px solid var(--primary);
    animation: slideUp 0.35s ease forwards;
    opacity: 0;
    transform: translateY(12px);
}

.inbox-item:hover {
    transform: translateX(4px);
    box-shadow: var(--shadow);
}

.inbox-item .inbox-title {
    font-weight: 600;
    font-size: 0.9rem;
    color: var(--text);
}

.inbox-item .inbox-preview {
    font-size: 0.85rem;
    color: var(--text-secondary);
    margin-top: 4px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.inbox-item .inbox-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.65rem;
    color: var(--text-secondary);
    margin-top: 6px;
}

.inbox-item .inbox-sender {
    font-weight: 600;
    font-size: 0.7rem;
    color: var(--primary);
}

.inbox-empty {
    text-align: center;
    padding: 40px 10px;
    color: var(--text-secondary);
}

.inbox-empty .empty-icon {
    font-size: 3rem;
    display: block;
    margin-bottom: 12px;
}

.inbox-actions {
    display: flex;
    gap: 6px;
    margin-top: 10px;
    flex-wrap: wrap;
}

.inbox-actions .btn-sm {
    padding: 6px 14px;
    font-size: 0.7rem;
    width: auto;
    border-radius: var(--radius-sm);
    cursor: pointer;
    transition: all 0.3s ease;
    font-weight: 600;
}

.inbox-actions .btn-sm:hover {
    transform: scale(1.02) translateY(-1px);
}

.inbox-actions .btn-secondary.btn-sm {
    background: var(--bg);
    border: 2px solid var(--border);
    color: var(--text);
}

.inbox-actions .btn-secondary.btn-sm:hover {
    border-color: var(--primary);
    background: var(--primary);
    color: #fff;
}

.inbox-actions .btn-primary.btn-sm {
    background: linear-gradient(135deg, #6c5ce7, #8b7cf7);
    color: #fff;
    border: none;
}

.inbox-actions .btn-primary.btn-sm:hover {
    box-shadow: 0 4px 15px rgba(108,92,231,0.3);
}

.inbox-actions .btn-danger.btn-sm {
    background: #e74c3c;
    color: #fff;
    border: none;
}

.inbox-actions .btn-danger.btn-sm:hover {
    background: #c0392b;
    box-shadow: 0 4px 15px rgba(231,76,60,0.3);
}

/* ===== MODALS ===== */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(10px);
    display: none;
    align-items: center;
    justify-content: center;
    z-index: 999;
    padding: 20px;
}

.modal-overlay.open {
    display: flex;
}

.modal {
    background: var(--card);
    border-radius: var(--radius);
    padding: 24px 20px;
    max-width: 420px;
    width: 100%;
    max-height: 90vh;
    overflow-y: auto;
    animation: modalIn 0.35s ease;
}

@keyframes modalIn {
    0% {
        opacity: 0;
        transform: scale(0.92) translateY(20px);
    }
    100% {
        opacity: 1;
        transform: scale(1) translateY(0);
    }
}

.modal-close {
    float: right;
    background: none;
    border: none;
    font-size: 1.3rem;
    color: var(--text-secondary);
    cursor: pointer;
    transition: var(--transition);
}

.modal-close:hover {
    transform: rotate(90deg);
}

.modal-title {
    font-size: 1.3rem;
    font-weight: 700;
    margin-bottom: 4px;
}

.modal-subtitle {
    color: var(--text-secondary);
    font-size: 0.85rem;
    margin-bottom: 14px;
}

/* ===== RESET PASSWORD MODAL ===== */
#resetPasswordModal .modal {
    max-width: 420px;
}

#resetPasswordModal .password-wrapper {
    position: relative;
}

#resetPasswordModal .password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--text-secondary);
    padding: 4px;
}

#resetPasswordModal .password-toggle:hover {
    color: var(--text);
}

/* ===== PLAN CARDS ===== */
.plan-card {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 18px;
    border: 2px solid var(--border);
    transition: var(--transition);
    margin: 10px 0;
    position: relative;
}

.plan-card.featured {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.08);
}

.plan-badge {
    position: absolute;
    top: -10px;
    right: 14px;
    background: var(--primary);
    color: #fff;
    padding: 2px 12px;
    border-radius: 40px;
    font-size: 0.65rem;
    font-weight: 700;
}

.plan-name {
    font-size: 1rem;
    font-weight: 700;
}

.plan-price {
    font-size: 1.8rem;
    font-weight: 800;
}

.plan-price span {
    font-size: 0.9rem;
    font-weight: 400;
    color: var(--text-secondary);
}

.plan-features {
    list-style: none;
    padding: 0;
    margin: 6px 0;
}

.plan-features li {
    padding: 3px 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
}

.payment-status {
    text-align: center;
    font-size: 0.85rem;
    margin-top: 6px;
    min-height: 24px;
}

/* ===== PROFILE ===== */
.profile-content {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

.profile-header {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
}

.profile-avatar {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.8rem;
    color: #fff;
}

.profile-info h2 {
    font-size: 1.2rem;
}

.profile-email {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.profile-plan {
    font-size: 0.85rem;
    font-weight: 600;
    margin-top: 2px;
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-bottom: 16px;
}

.stat-card {
    background: var(--bg);
    padding: 10px;
    border-radius: var(--radius-sm);
    text-align: center;
    transition: var(--transition);
}

.stat-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.stat-label {
    display: block;
    font-size: 0.65rem;
    color: var(--text-secondary);
}

.stat-value {
    font-size: 1.1rem;
    font-weight: 700;
}

.profile-section {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 14px;
    margin-bottom: 14px;
}

.profile-section h3 {
    font-size: 0.95rem;
    margin-bottom: 10px;
}

.premium-tag {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    font-size: 0.45rem;
    font-weight: 700;
    padding: 2px 8px;
    border-radius: 40px;
    color: #0b0b1a;
}

.premium-section {
    border: 2px solid #fbbf24;
}

.link-preview {
    margin-top: 8px;
    padding: 16px;
    border-radius: var(--radius-sm);
    background: #6c5ce7;
    color: #fff;
    text-align: center;
    transition: var(--transition);
}

.profile-actions {
    display: flex;
    flex-direction: column;
    gap: 6px;
    margin-top: 12px;
}

/* ===== HISTORY ===== */
.history-content {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

.history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.history-header h2 {
    font-size: 1.1rem;
}

.history-count {
    background: var(--bg);
    padding: 4px 10px;
    border-radius: 40px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ===== ABOUT PAGE ===== */
.about-content {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
    height: 100%;
    scroll-behavior: smooth;
    position: relative;
}

.about-content::-webkit-scrollbar {
    width: 4px;
}

.about-content::-webkit-scrollbar-track {
    background: var(--bg);
}

.about-content::-webkit-scrollbar-thumb {
    background: var(--primary);
    border-radius: 4px;
}

.about-hero {
    text-align: center;
    padding: 20px 0 16px;
    position: relative;
}

.about-hero-logo {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: rgba(108, 92, 231, 0.1);
    padding: 12px;
    margin: 0 auto 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    position: relative;
}

.about-hero-logo img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: contain;
}

.about-hero::before,
.about-hero::after,
.about-content .floating-image-1,
.about-content .floating-image-2,
.about-content .floating-image-3,
.about-content .floating-image-4 {
    content: '';
    position: absolute;
    border-radius: 50%;
    background: var(--primary);
    opacity: 0.08;
    pointer-events: none;
}

.about-hero::before {
    width: 60px;
    height: 60px;
    top: -10px;
    right: 20px;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    opacity: 0.1;
}

.about-hero::after {
    width: 40px;
    height: 40px;
    bottom: 20px;
    left: 10px;
    background: linear-gradient(135deg, #a29bfe, #6c5ce7);
    opacity: 0.08;
}

.about-content .floating-image-1 {
    width: 35px;
    height: 35px;
    top: 15%;
    right: 5%;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    opacity: 0.15;
    animation: floatSlow 8s ease-in-out infinite;
}

.about-content .floating-image-2 {
    width: 25px;
    height: 25px;
    bottom: 25%;
    left: 3%;
    background: linear-gradient(135deg, #10b981, #34d399);
    opacity: 0.12;
    animation: floatSlow 10s ease-in-out infinite reverse;
}

.about-content .floating-image-3 {
    width: 45px;
    height: 45px;
    top: 40%;
    right: 2%;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    opacity: 0.08;
    animation: floatSlow 7s ease-in-out infinite 2s;
}

.about-content .floating-image-4 {
    width: 30px;
    height: 30px;
    bottom: 10%;
    right: 8%;
    background: linear-gradient(135deg, #e74c3c, #f39c12);
    opacity: 0.1;
    animation: floatSlow 9s ease-in-out infinite 1s;
}

.about-card .card-float {
    position: absolute;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    pointer-events: none;
    opacity: 0.08;
}

.about-card .card-float-1 {
    top: 8px;
    right: 12px;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    animation: floatSmall 6s ease-in-out infinite;
}

.about-card .card-float-2 {
    bottom: 8px;
    left: 12px;
    width: 18px;
    height: 18px;
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
    animation: floatSmall 7s ease-in-out infinite reverse;
}

@keyframes floatSlow {
    0%, 100% {
        transform: translateY(0) scale(1);
    }
    33% {
        transform: translateY(-8px) scale(1.05);
    }
    66% {
        transform: translateY(4px) scale(0.95);
    }
}

@keyframes floatSmall {
    0%, 100% {
        transform: translateY(0) rotate(0deg);
    }
    50% {
        transform: translateY(-6px) rotate(180deg);
    }
}

.developer-card {
    border: 2px solid var(--primary);
    position: relative;
    overflow: hidden;
}

.developer-card::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -50%;
    width: 100%;
    height: 100%;
    background: radial-gradient(circle, rgba(108, 92, 231, 0.03) 0%, transparent 70%);
    pointer-events: none;
}

.developer-profile {
    display: flex;
    gap: 16px;
    margin-top: 8px;
    position: relative;
    z-index: 1;
}

.developer-avatar {
    width: 70px;
    height: 70px;
    border-radius: 50%;
    flex-shrink: 0;
    overflow: hidden;
    background: var(--card);
    border: 3px solid var(--primary);
    position: relative;
    box-shadow: 0 4px 15px rgba(108, 92, 231, 0.2);
    transition: var(--transition);
}

.developer-avatar:hover {
    transform: scale(1.05) rotate(-3deg);
    box-shadow: 0 8px 25px rgba(108, 92, 231, 0.3);
}

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

.developer-avatar::before {
    content: '';
    position: absolute;
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--primary);
    top: -4px;
    right: -4px;
    opacity: 0.2;
    animation: pulseDot 2s ease-in-out infinite;
}

.developer-avatar::after {
    content: '';
    position: absolute;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: #fbbf24;
    bottom: -4px;
    left: -4px;
    opacity: 0.3;
    animation: pulseDot 2.5s ease-in-out infinite reverse;
}

@keyframes pulseDot {
    0%, 100% {
        transform: scale(1);
        opacity: 0.2;
    }
    50% {
        transform: scale(1.5);
        opacity: 0.5;
    }
}

.developer-info h4 {
    font-size: 1rem;
    margin: 0 0 2px;
}

.developer-title {
    font-size: 0.75rem;
    color: var(--primary);
    font-weight: 600;
}

.developer-bio {
    font-size: 0.8rem;
    color: var(--text-secondary);
    margin: 6px 0 8px;
    line-height: 1.5;
}

.developer-links {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
}

.dev-link {
    display: inline-block;
    padding: 4px 10px;
    background: var(--card);
    border-radius: 20px;
    font-size: 0.7rem;
    color: var(--text-secondary);
    text-decoration: none;
    transition: var(--transition);
    border: 1px solid var(--border);
}

.dev-link:hover {
    border-color: var(--primary);
    color: var(--primary);
    transform: translateY(-2px) scale(1.02);
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 8px;
}

.stat-item {
    text-align: center;
    padding: 12px;
    background: var(--card);
    border-radius: var(--radius-sm);
    position: relative;
    transition: var(--transition);
}

.stat-item:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.stat-item::before {
    content: '';
    position: absolute;
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: var(--primary);
    top: 6px;
    right: 8px;
    opacity: 0.2;
}

.stat-number {
    display: block;
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary);
}

.stat-label {
    font-size: 0.65rem;
    color: var(--text-secondary);
}

.about-card {
    background: var(--bg);
    border-radius: var(--radius-sm);
    padding: 16px;
    margin-bottom: 12px;
    position: relative;
    overflow: hidden;
    transition: var(--transition);
}

.about-card:hover {
    transform: translateY(-2px);
    box-shadow: var(--shadow);
}

.about-card h3 {
    font-size: 0.95rem;
    margin-bottom: 8px;
}

.about-card p {
    color: var(--text-secondary);
    font-size: 0.85rem;
    line-height: 1.6;
}

.about-card a {
    color: var(--primary);
    text-decoration: none;
}

.about-card a:hover {
    text-decoration: underline;
}

.feature-list {
    list-style: none;
    padding: 0;
}

.feature-list li {
    padding: 4px 0;
    font-size: 0.85rem;
    color: var(--text-secondary);
    position: relative;
    padding-left: 20px;
}

.feature-list li::before {
    content: '◆';
    position: absolute;
    left: 0;
    color: var(--primary);
    font-size: 0.5rem;
    top: 50%;
    transform: translateY(-50%);
}

.about-footer {
    text-align: center;
    padding: 16px 0 8px;
    color: var(--text-secondary);
    font-size: 0.75rem;
}

.about-footer .heart {
    color: #e74c3c;
    display: inline-block;
    animation: heartBeat 2s ease-in-out infinite;
}

@keyframes heartBeat {
    0%, 100% {
        transform: scale(1);
    }
    15% {
        transform: scale(1.2);
    }
    30% {
        transform: scale(1);
    }
    45% {
        transform: scale(1.1);
    }
    60% {
        transform: scale(1);
    }
}

.footer-version {
    font-size: 0.6rem;
    color: var(--text-secondary);
    margin-top: 2px;
}

/* ===== PREMIUM PAGE ===== */
.premium-content {
    padding: 16px;
    overflow-y: auto;
    flex: 1;
}

.premium-title {
    font-size: 1.3rem;
    font-weight: 700;
    text-align: center;
}

.premium-subtitle {
    text-align: center;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

.premium-status {
    text-align: center;
    margin-top: 16px;
    padding: 12px;
    border-radius: var(--radius-sm);
}

.premium-active {
    background: #2ecc71;
    color: #fff;
    padding: 12px;
    border-radius: var(--radius-sm);
    font-weight: 600;
}

/* ===== FORM ELEMENTS ===== */
.form-group {
    margin-bottom: 12px;
}

.form-group label {
    display: block;
    font-size: 0.8rem;
    font-weight: 600;
    color: var(--text);
    margin-bottom: 4px;
}

.form-group input,
.form-group select {
    width: 100%;
    padding: 10px 14px;
    border: 2px solid var(--border);
    border-radius: var(--radius-sm);
    background: var(--bg);
    color: var(--text);
    font-size: 0.9rem;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus {
    border-color: var(--primary);
    box-shadow: 0 0 0 4px rgba(108, 92, 231, 0.12);
    outline: none;
}

.form-group input[type="color"] {
    padding: 4px;
    height: 50px;
    cursor: pointer;
}

.password-wrapper {
    position: relative;
}

.password-wrapper input {
    padding-right: 44px;
}

.password-toggle {
    position: absolute;
    right: 12px;
    top: 50%;
    transform: translateY(-50%);
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1.1rem;
    color: var(--text-secondary);
    padding: 4px;
}

.password-toggle:hover {
    color: var(--text);
}

.error-msg {
    color: #e74c3c;
    font-size: 0.8rem;
    min-height: 20px;
    text-align: center;
    margin-top: 6px;
}

/* ===== AUTH PAGES ===== */
.auth-page {
    max-width: 400px;
    width: 100%;
    margin: 0 auto;
    padding: 20px;
    min-height: 100vh;
    display: flex;
    align-items: center;
}

.auth-container {
    background: var(--card);
    border-radius: var(--radius);
    padding: 32px 24px;
    box-shadow: var(--shadow);
    position: relative;
    width: 100%;
}

.auth-back {
    position: absolute;
    top: 16px;
    left: 20px;
    color: var(--text-secondary);
    text-decoration: none;
    font-size: 0.9rem;
}

.auth-back:hover {
    color: var(--primary);
}

.auth-header {
    text-align: center;
    margin-bottom: 30px;
    margin-top: 8px;
}

.auth-logo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: rgba(108, 92, 231, 0.1);
    padding: 10px;
    margin: 0 auto 10px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.auth-logo img {
    width: 100%;
    height: 100%;
    border-radius: 50%;
    object-fit: contain;
}

.auth-header h2 {
    font-size: 1.8rem;
    font-weight: 700;
    background: linear-gradient(135deg, #6c5ce7, #a29bfe);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
}

.auth-header p {
    color: var(--text-secondary);
}

.auth-switch {
    color: var(--text-secondary);
    text-align: center;
    font-size: 0.95rem;
    margin-top: 16px;
}

.auth-switch a {
    color: var(--primary);
    font-weight: 600;
    text-decoration: none;
}

.auth-switch a:hover {
    text-decoration: underline;
}

/* ===== GOOGLE BUTTON ===== */
.btn-google {
    background: var(--card);
    border: 2px solid var(--border);
    padding: 14px;
    border-radius: var(--radius-sm);
    font-weight: 500;
    color: var(--text);
    transition: var(--transition);
    cursor: pointer;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
}

.btn-google:hover {
    border-color: var(--primary);
    transform: translateY(-2px);
}

.divider {
    text-align: center;
    color: var(--text-secondary);
    padding: 12px 0;
    font-size: 0.9rem;
    position: relative;
}

.divider::before,
.divider::after {
    content: '';
    position: absolute;
    top: 50%;
    width: 40%;
    height: 1px;
    background: var(--border);
}

.divider::before {
    left: 0;
}
.divider::after {
    right: 0;
}

/* ===== LOADING STATE ===== */
.loading-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--border);
    border-top-color: var(--primary);
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin-bottom: 16px;
}

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

/* ===== TOAST ===== */
.toast {
    position: fixed;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    background: var(--text);
    color: var(--bg);
    padding: 10px 24px;
    border-radius: 60px;
    font-weight: 500;
    box-shadow: var(--shadow);
    opacity: 0;
    transition: opacity 0.35s;
    pointer-events: none;
    z-index: 9999;
    font-size: 0.85rem;
    max-width: 90%;
    text-align: center;
}

.toast.show {
    opacity: 1;
}

/* ===== CUSTOM LINK FORM ===== */
.custom-link-form {
    margin-top: 10px;
}

.custom-link-form .form-group {
    margin-bottom: 12px;
}

/* ===== RESPONSIVE ===== */
@media (max-width: 480px) {
    .app-wrapper {
        height: 100vh;
        border-radius: 0;
        box-shadow: none;
    }

    .splash-title {
        font-size: 2rem;
    }
    .splash-icon {
        width: 56px;
        height: 56px;
        padding: 10px;
    }

    .content {
        padding: 10px 12px;
        padding-bottom: 70px;
    }

    .modal {
        padding: 16px;
        margin: 10px;
    }

    .profile-stats {
        grid-template-columns: 1fr 1fr;
    }

    .composer-actions {
        flex-direction: column;
    }
    .composer-actions .btn-secondary {
        flex: 1;
    }

    .header-logo {
        width: 28px;
        height: 28px;
    }
    .header-left h1 {
        font-size: 0.95rem;
    }

    .avatar {
        width: 30px;
        height: 30px;
        font-size: 0.85rem;
    }

    .premium-badge {
        font-size: 0.4rem;
        padding: 1px 6px;
    }

    .theme-toggle {
        width: 30px;
        height: 30px;
        font-size: 0.8rem;
    }

    .nav-rail-toggle {
        width: 32px;
        height: 32px;
        font-size: 1rem;
    }

    .hush-modal-enhanced {
        max-width: 100% !important;
        margin: 10px !important;
        border-radius: 20px !important;
    }
    
    .hush-enhanced-header {
        padding: 16px !important;
    }
    
    .hush-enhanced-body {
        padding: 16px !important;
    }
    
    .hush-enhanced-footer {
        padding: 12px 16px 16px !important;
    }
    
    .hush-message-card {
        padding: 12px !important;
        gap: 10px !important;
    }
    
    .hush-message-icon {
        width: 32px !important;
        height: 32px !important;
        font-size: 1.2rem !important;
    }
    
    .hush-share-buttons {
        gap: 6px !important;
    }
    
    .hush-share-btn {
        width: 32px !important;
        height: 32px !important;
    }
    
    .hush-share-btn svg {
        width: 14px !important;
        height: 14px !important;
    }
    
    .hush-actions-row {
        flex-direction: column !important;
        gap: 6px !important;
    }

    .hush-action-btn {
        padding: 8px !important;
        font-size: 0.75rem !important;
        white-space: normal !important;
    }
    
    .hush-reply-input-wrapper {
        flex-direction: column !important;
    }
    
    .hush-reply-send-btn {
        padding: 8px !important;
    }

    #qrCodeContainer {
        padding: 24px 16px !important;
        max-width: 95% !important;
        border-radius: 20px !important;
    }

    .qr-header-icon {
        width: 40px !important;
        height: 40px !important;
        font-size: 1.2rem !important;
    }

    .qr-title {
        font-size: 1rem !important;
    }

    .qr-code-wrapper {
        padding: 16px !important;
        min-height: 180px !important;
    }

    .qr-brand-overlay {
        width: 32px !important;
        height: 32px !important;
        bottom: 20px !important;
        right: 20px !important;
        padding: 4px !important;
    }

    .qr-footer {
        flex-direction: column !important;
    }

    .qr-download-btn,
    .qr-share-btn {
        padding: 10px !important;
        font-size: 0.8rem !important;
    }

    .nav-rail {
        width: 100%;
        max-width: 85%;
    }
    
    .message-item-actions {
        gap: 4px;
    }
    .message-item-actions button {
        font-size: 0.65rem;
        padding: 2px 6px;
    }

    .profile-content,
    .history-content,
    .about-content,
    .premium-content {
        padding: 12px;
    }

    .inbox-actions {
        flex-direction: column;
    }
    .inbox-actions .btn-sm {
        width: 100%;
    }
    
    .inbox-item {
        padding: 10px 12px;
    }

    .developer-profile {
        flex-direction: column;
        align-items: center;
        text-align: center;
    }

    .developer-avatar {
        width: 80px;
        height: 80px;
    }

    .developer-links {
        justify-content: center;
    }

    .stats-grid {
        grid-template-columns: 1fr 1fr;
    }
    
    .about-hero::before {
        width: 40px;
        height: 40px;
    }
    
    .about-hero::after {
        width: 30px;
        height: 30px;
    }
    
    .about-content .floating-image-1,
    .about-content .floating-image-2,
    .about-content .floating-image-3,
    .about-content .floating-image-4 {
        display: none;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .app-wrapper {
        max-width: 480px;
        margin: 0 auto;
        height: 100vh;
        border-radius: var(--radius);
        box-shadow: var(--shadow);
    }
}

@media (min-width: 769px) {
    body {
        display: flex;
        align-items: center;
        justify-content: center;
        padding: 20px;
        background: var(--bg);
    }

    .app-wrapper {
        max-width: 480px;
        height: 90vh;
        border-radius: var(--radius);
        box-shadow: var(--shadow);
    }

    .nav-rail {
        max-width: 300px;
    }
}