    /* БАЗОВЫЕ НАСТРОЙКИ */
    * { 
        box-sizing: border-box; 
        margin: 0; 
        padding: 0; 
        outline: none; 
        -webkit-tap-highlight-color: transparent; 
        user-select: none; 
        font-family: 'SF Pro Display', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif; 
    }

    :root { 
        --safe-area-top: env(safe-area-inset-top); 
        --safe-area-bottom: env(safe-area-inset-bottom); 
        --primary: #666666; 
        --blob-color-1: #2c5364; 
        --blob-color-2: #203a43; 
        --blob-color-3: #141E30;
        --bg-color: #0f2027;
        --glass: rgba(20, 20, 20, 0.6); 
        --border: rgba(255, 255, 255, 0.15); 
        --shadow: 0 8px 32px 0 rgba(0, 0, 0, 0.3);
        --warn: #FFAA00; 
        --danger: #FF3333; 
        --success: #00B956;
    }

    body { 
        background-color: var(--bg-color); 
        color: #fff; 
        min-height: 100vh; 
        overflow-x: hidden; 
        padding-bottom: 100px; 
        transition: background-color 0.8s ease; 
    }

    .background-container { 
        position: fixed; 
        top: 0; 
        left: 0; 
        width: 100%; 
        height: 100%; 
        z-index: -1; 
        overflow: hidden; 
        pointer-events: none; 
    }
    
    .blob { 
        position: absolute; 
        border-radius: 50%; 
        filter: blur(80px); 
        opacity: 0.5; 
        animation: float 10s infinite ease-in-out; 
        transition: background-color 1.0s ease; 
    }
    
    .blob-1 { width: 400px; height: 400px; top: -100px; left: -100px; background: var(--blob-color-1); }
    .blob-2 { width: 500px; height: 500px; bottom: -150px; right: -150px; background: var(--blob-color-2); animation-delay: -5s; }
    .blob-3 { width: 300px; height: 300px; top: 40%; left: 30%; background: var(--blob-color-3); animation-duration: 15s; }
    
    .blob-overlay { 
        position: absolute; 
        inset: 0; 
        background: url('data:image/svg+xml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIHdpZHRoPSI0MDAiIGhlaWdodD0iNDAwIj48ZmlsdGVyIGlkPSJnoiPjxmZVR1cmJ1bGVuY2UgdHlwZT0iZnJhY3RhbE5vaXNlIiBiYXNlRnJlcXVlbmN5PSIwLjY1IiBudW1PY3RhdmVzPSIzIiBzdGl0Y2hUaWxlcz0ic3RpdGNoIi8+PC9maWx0ZXI+PHJlY3Qgd2lkdGg9IjEwMCUiIGhlaWdodD0iMTAwJSIgZmlsdGVyPSJ1cmwoI2cpIiBvcGFjaXR5PSIwLjAzIi8+PC9zdmc+'); 
        opacity: 0.4; 
    }

    /* UI ЭЛЕМЕНТЫ */
    .top-bar { 
        position: sticky; 
        top: 0; 
        z-index: 100; 
        background: rgba(20, 20, 20, 0.8); 
        backdrop-filter: blur(20px); 
        -webkit-backdrop-filter: blur(20px); 
        padding: 15px; 
        padding-top: calc(15px + var(--safe-area-top)); 
        border-bottom: 1px solid var(--border); 
        display: flex; 
        gap: 15px; 
    }
    
    .operator-btn { 
        flex: 1; 
        padding: 14px; 
        border-radius: 14px; 
        background: rgba(255,255,255,0.05); 
        color: #888; 
        font-weight: 700; 
        text-align: center; 
        text-transform: uppercase; 
        letter-spacing: 1px; 
        transition: all 0.3s ease; 
        border: 1px solid transparent; 
    }
    
    .operator-btn.active { 
        background: rgba(255, 255, 255, 0.1); 
        color: var(--primary); 
        border-color: var(--primary); 
        box-shadow: 0 0 20px rgba(255, 255, 255, 0.1); 
    }
    
    .screen { 
        display: none; 
        padding: 20px; 
        opacity: 0; 
        transform: translateY(10px); 
        transition: opacity 0.3s, transform 0.3s; 
    }
    .screen.visible { display: block; opacity: 1; transform: translateY(0); }
    
    .card { 
        background: var(--glass); 
        border: 1px solid var(--border); 
        border-radius: 24px; 
        padding: 24px; 
        margin-bottom: 20px; 
        backdrop-filter: blur(15px); 
        -webkit-backdrop-filter: blur(15px); 
        box-shadow: var(--shadow); 
    }
    
    .card-header { 
        font-size: 11px; 
        color: rgba(255,255,255,0.6); 
        text-transform: uppercase; 
        letter-spacing: 1.5px; 
        margin-bottom: 15px; 
        display: flex; 
        justify-content: space-between; 
        font-weight: 700; 
    }
    
    .balance-large { 
        font-size: 54px; 
        font-weight: 800; 
        text-align: center; 
        margin: 10px 0; 
        text-shadow: 0 5px 15px rgba(0,0,0,0.3); 
        color: var(--primary); 
        transition: color 0.3s; 
    }
    
    .action-button { 
        width: 100%; 
        padding: 18px; 
        border: none; 
        border-radius: 16px; 
        font-size: 16px; 
        font-weight: bold; 
        color: #fff; 
        text-transform: uppercase; 
        cursor: pointer; 
        display: flex; 
        align-items: center; 
        justify-content: center; 
        gap: 10px; 
        box-shadow: 0 10px 20px rgba(0,0,0,0.2); 
        transition: transform 0.1s; 
    }
    .action-button:active { transform: scale(0.96); }
    
    .btn-main-style { background: linear-gradient(135deg, var(--primary), #333); text-shadow: 0 1px 2px rgba(0,0,0,0.5); }
    .btn-neutral { background: #444; }
    .btn-danger { background: #ff3333; }
    .btn-edit { background: #FFAA00; color: #000; }
    
    .input-group { margin-bottom: 15px; }
    .input-label { display: block; font-size: 12px; color: #aaa; margin-bottom: 8px; }
    .custom-input { width: 100%; padding: 15px; background: rgba(0,0,0,0.4); border: 1px solid var(--border); border-radius: 14px; color: #fff; font-size: 16px; }
    .custom-input select { background: #111; color: white; }
    .custom-input option { background: #222; }
    .custom-input:focus { border-color: var(--primary); box-shadow: 0 0 0 2px rgba(255,255,255,0.1); }
    
    .checkbox-group { display: flex; align-items: center; gap: 10px; margin-bottom: 15px; background: rgba(0,0,0,0.2); padding: 10px; border-radius: 12px; }
    .custom-checkbox { width: 20px; height: 20px; accent-color: var(--primary); }

    /* --- ГЕЙМИФИКАЦИЯ (НОВЫЙ CSS) --- */
    .xp-container { background: rgba(0,0,0,0.3); height: 6px; width: 100%; position: absolute; bottom: 0; left: 0; }
    .xp-fill { height: 100%; background: linear-gradient(90deg, var(--primary), #fff); width: 0%; transition: width 0.5s ease; box-shadow: 0 0 10px var(--primary); }
    .level-badge { position: absolute; top: 15px; right: 15px; background: rgba(255,255,255,0.1); padding: 5px 10px; border-radius: 12px; font-size: 10px; font-weight: 800; border: 1px solid var(--border); backdrop-filter: blur(5px); }
    
    .achievement-unlock { position: fixed; top: 80px; right: 20px; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); padding: 15px; border-radius: 16px; box-shadow: 0 10px 40px rgba(102, 126, 234, 0.5); animation: slideInRight 0.5s, shake 0.5s 0.5s; z-index: 10000; max-width: 300px; display: flex; gap: 10px; align-items: center; }
    .achievement-icon { font-size: 32px; animation: bounce 1s infinite; }
    .achievement-title { font-size: 10px; text-transform: uppercase; opacity: 0.8; }
    .achievement-name { font-size: 14px; font-weight: bold; margin: 2px 0; }
    .achievement-xp { font-size: 12px; color: #FFD700; font-weight: bold; }
    
    .level-up-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.95); display: flex; align-items: center; justify-content: center; z-index: 99999; animation: fadeIn 0.3s; }
    .level-up-content { background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); padding: 30px; border-radius: 24px; text-align: center; max-width: 90%; animation: scaleIn 0.5s cubic-bezier(0.68, -0.55, 0.265, 1.55); }
    .level-number { font-size: 80px; font-weight: 900; background: linear-gradient(45deg, #FFD700, #FFA500); -webkit-background-clip: text; -webkit-text-fill-color: transparent; }

    /* Темы */
    .theme-selector { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 10px; }
    .theme-btn { height: 40px; border-radius: 8px; border: 2px solid transparent; cursor: pointer; transition: transform 0.2s; }
    .theme-btn:active { transform: scale(0.95); }
    .theme-btn.active { border-color: #fff; transform: scale(1.05); }
    #matrix-canvas { position: fixed; top: 0; left: 0; width: 100%; height: 100%; z-index: -2; opacity: 0; transition: opacity 1s; pointer-events: none; }
    
    /* AR контейнер */
    #ar-container { position: fixed; inset: 0; z-index: 9998; display: none; background: rgba(0,0,0,0.95); }
    #ar-container canvas { display: block; }

    /* --- АНАЛИТИКА, ГОЛОС, НЕЙРО --- */
    .dashboard-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 15px; padding-bottom: 20px; }
    .chart-container { background: rgba(255,255,255,0.05); padding: 15px; border-radius: 16px; border: 1px solid var(--border); backdrop-filter: blur(10px); min-height: 250px; position: relative; display: flex; flex-direction: column; justify-content: center; }
    .chart-container.large { grid-column: 1 / -1; min-height: 300px; }
    .chart-container.wide { grid-column: 1 / -1; overflow-x: auto; }

    #voice-indicator { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); z-index: 10000; text-align: center; pointer-events: none; }
    .voice-pulse { position: relative; width: 100px; height: 100px; margin: 0 auto; }
    .pulse-ring { position: absolute; inset: 0; border: 3px solid var(--primary); border-radius: 50%; animation: pulse-ring 2s cubic-bezier(0.4, 0, 0.6, 1) infinite; }
    .pulse-ring:nth-child(2) { animation-delay: 0.5s; }
    .pulse-ring:nth-child(3) { animation-delay: 1s; }
    @keyframes pulse-ring { 0% { transform: scale(0.8); opacity: 1; } 100% { transform: scale(2); opacity: 0; } }
    .speech-bubble { position: fixed; bottom: 160px; left: 50%; transform: translateX(-50%); background: rgba(20,20,20,0.9); border: 1px solid var(--primary); padding: 15px 25px; border-radius: 20px; color: white; font-size: 14px; max-width: 80%; text-align: center; animation: fadeInUp 0.3s forwards; z-index: 9998; backdrop-filter: blur(5px); }

    .prediction-main { margin: 15px 0; animation: fadeIn 0.5s; }
    .prediction-amount { font-size: 42px; font-weight: 800; color: #fff; text-shadow: 0 0 20px var(--primary); margin: 10px 0; }
    .prediction-date { font-size: 18px; color: #aaa; }
    .confidence-meter { background: rgba(255,255,255,0.1); height: 6px; border-radius: 3px; margin: 15px auto; width: 80%; overflow: hidden; position: relative; }
    .confidence-bar { height: 100%; background: linear-gradient(90deg, #ff3333, #00B956); transition: width 1.5s ease; box-shadow: 0 0 10px #00B956; }

    /* ПРОЧИЕ СТИЛИ */
    .sched-control { display: flex; gap: 10px; margin-bottom: 15px; }
    .sched-chips-container { display: flex; flex-wrap: wrap; gap: 8px; }
    .sched-chip { background: rgba(255,255,255,0.1); border: 1px solid var(--border); padding: 8px 14px; border-radius: 20px; font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 8px; animation: fadeIn 0.3s; }
    .sched-chip-del { width: 18px; height: 18px; background: rgba(255,50,50,0.3); border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 10px; cursor: pointer; }
    
    .warning-box { background: rgba(255, 50, 50, 0.15); border: 1px solid #ff3333; color: #ffcccc; padding: 15px; border-radius: 14px; margin-bottom: 20px; font-size: 13px; line-height: 1.4; display: none; backdrop-filter: blur(10px); }
    .warning-box.visible { display: block; animation: fadeIn 0.5s; }
    
    .phone-row { padding: 16px; background: rgba(255,255,255,0.03); border-radius: 16px; margin-bottom: 12px; position: relative; border-left: 4px solid #555; }
    .phone-row.ok { border-left-color: var(--success); }
    .phone-row.warn { border-left-color: var(--warn); }
    .phone-row.bad { border-left-color: var(--danger); }
    .phone-main { font-size: 18px; font-weight: 700; color: #fff; letter-spacing: 0.5px; }
    .phone-sub { font-size: 13px; color: #aaa; margin-top: 6px; display: flex; justify-content: space-between; }
    .phone-cost { font-weight: 700; color: var(--primary); }
    .card-actions { position: absolute; right: 10px; top: 10px; display: flex; gap: 8px; }
    .btn-mini { background: rgba(255,255,255,0.1); border: none; width: 32px; height: 32px; border-radius: 50%; color: #fff; font-size: 14px; display: flex; align-items: center; justify-content: center; cursor: pointer; transition: background 0.2s; }
    .btn-mini:active { background: rgba(255,255,255,0.3); }
    .btn-mini-del { background: rgba(255, 50, 50, 0.15); color: #ff5555; }
    
    .tariff-type-badge { display: inline-block; padding: 3px 8px; border-radius: 6px; font-size: 10px; font-weight: 700; margin-left: 8px; text-transform: uppercase; }
    .badge-30days { background: rgba(102, 126, 234, 0.3); color: #667eea; }
    .badge-monthly { background: rgba(0, 185, 86, 0.3); color: #00B956; }
    .badge-daily { background: rgba(255, 170, 0, 0.3); color: #FFAA00; }
    .badge-custom { background: rgba(255, 255, 255, 0.2); color: #fff; }
    
    .auto-check-indicator { position: fixed; top: calc(20px + var(--safe-area-top)); right: 20px; background: rgba(102, 126, 234, 0.9); padding: 10px 16px; border-radius: 12px; font-size: 12px; font-weight: 700; z-index: 200; animation: slideInRight 0.3s ease; box-shadow: 0 8px 16px rgba(0,0,0,0.3); }
    
    .btn-group-ios { display: flex; flex-direction: column; gap: 0; background: rgba(255,255,255,0.05); border-radius: 12px; overflow: hidden; margin-top: 10px; border: 1px solid rgba(255,255,255,0.05); }
    .btn-ios { background: transparent; border: none; border-bottom: 1px solid rgba(255,255,255,0.05); padding: 16px; color: #fff; font-size: 15px; font-weight: 400; cursor: pointer; transition: background 0.2s; display: flex; align-items: center; gap: 12px; text-align: left; width: 100%; }
    .btn-ios:last-child { border-bottom: none; }
    .btn-ios:active { background: rgba(255,255,255,0.1); }
    .btn-ios span { flex: 1; }
    .btn-ios.danger { color: #ff453a; }
    .btn-ios.primary { color: #0a84ff; font-weight: 600; }
    .btn-ios.warn { color: #ff9f0a; }
    
    .ussd-quick { margin-top: 15px; }
    .ussd-toggle { width: 100%; background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.15); padding: 12px 16px; border-radius: 12px; color: #fff; font-size: 14px; font-weight: 600; cursor: pointer; display: flex; justify-content: space-between; align-items: center; transition: all 0.2s; }
    .ussd-toggle:active { background: rgba(255,255,255,0.1); }
    .ussd-list { margin-top: 10px; background: rgba(20,20,20,0.8); backdrop-filter: blur(20px); border: 1px solid rgba(255,255,255,0.15); border-radius: 12px; padding: 6px; display: none; max-height: 300px; overflow-y: auto; }
    .ussd-list.active { display: block; animation: slideDown 0.3s ease; }
    .ussd-item { padding: 12px 14px; border-radius: 8px; cursor: pointer; transition: background 0.2s; display: flex; justify-content: space-between; align-items: center; margin-bottom: 4px; }
    .ussd-item:active { background: rgba(255,255,255,0.15); }
    .ussd-item-left { display: flex; align-items: center; gap: 10px; flex: 1; }
    .ussd-item-icon { font-size: 18px; }
    .ussd-item-info { flex: 1; }
    .ussd-item-title { font-size: 14px; font-weight: 600; color: #fff; margin-bottom: 2px; }
    .ussd-item-desc { font-size: 11px; color: #888; }
    .ussd-item-code { font-size: 12px; font-family: monospace; color: var(--primary); font-weight: 700; }
    .ussd-empty { text-align: center; padding: 20px; color: #666; font-size: 13px; }
    @keyframes slideDown { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
    
    .log-container { max-height: 350px; overflow-y: auto; background: rgba(0,0,0,0.3); border-radius: 14px; padding: 10px; }
    .log-item { padding: 12px; border-bottom: 1px solid rgba(255,255,255,0.05); font-size: 13px; display: flex; gap: 12px; align-items: flex-start; transition: background 0.2s; cursor: pointer; }
    .log-item:hover { background: rgba(255,255,255,0.03); }
    .log-item:last-child { border-bottom: none; }
    .log-icon { font-size: 20px; flex-shrink: 0; width: 30px; text-align: center; }
    .log-content { flex: 1; }
    .log-header { display: flex; justify-content: space-between; align-items: flex-start; margin-bottom: 4px; gap: 10px; }
    .log-time { color: #666; font-size: 11px; margin-top: 4px; }
    .log-title { font-weight: 700; color: #fff; font-size: 14px; margin-bottom: 4px; }
    .log-text { color: #aaa; word-break: break-word; line-height: 1.4; font-size: 12px; }
    .log-badge { display: inline-block; padding: 3px 8px; border-radius: 6px; font-size: 10px; font-weight: 700; text-transform: uppercase; white-space: nowrap; background: rgba(255,255,255,0.1); }
    .journal-filters { display: flex; gap: 5px; margin-bottom: 15px; overflow-x: auto; padding-bottom: 5px; }
    .filter-btn { padding: 8px 12px; border-radius: 10px; background: rgba(255,255,255,0.1); border: none; color: #aaa; font-size: 12px; font-weight: 600; white-space: nowrap; cursor: pointer; }
    .filter-btn.active { background: var(--primary); color: #fff; }
    
    .bottom-nav { position: fixed; bottom: 0; left: 0; right: 0; height: 80px; background: rgba(15,15,15,0.9); backdrop-filter: blur(20px); -webkit-backdrop-filter: blur(20px); border-top: 1px solid var(--border); display: flex; justify-content: space-around; align-items: center; padding-bottom: var(--safe-area-bottom); z-index: 90; }
    .nav-item { display: flex; flex-direction: column; align-items: center; gap: 6px; color: #666; font-size: 9px; width: 1; font-weight: 600; transition: color 0.3s; }
    .nav-item.active { color: var(--primary); }
    .nav-icon { width: 24px; height: 24px; fill: currentColor; }
    
    .alarm-screen { position: fixed; inset: 0; z-index: 1000; background: rgba(0,0,0,0.95); display: none; flex-direction: column; align-items: center; justify-content: center; animation: redPulse 1s infinite; backdrop-filter: blur(10px); }
    .alarm-screen.active { display: flex; }
    @keyframes redPulse { 50% { background: rgba(50,0,0,0.8); } }
    .alarm-big-text { font-size: 30px; color: #ff3333; font-weight: 900; margin-bottom: 20px; }
    .alarm-amount { font-size: 60px; color: #fff; margin-bottom: 40px; }
    .ai-badge { display: inline-block; background: linear-gradient(135deg, #667eea 0%, #764ba2 100%); padding: 4px 10px; border-radius: 8px; font-size: 10px; font-weight: 700; letter-spacing: 1px; margin-left: 8px; }
    .prediction-card { background: linear-gradient(135deg, rgba(102, 126, 234, 0.1) 0%, rgba(118, 75, 162, 0.1) 100%); border: 1px solid rgba(102, 126, 234, 0.3); border-radius: 16px; padding: 16px; margin-bottom: 15px; }
    .prediction-item { display: flex; justify-content: space-between; align-items: center; padding: 12px; background: rgba(0,0,0,0.2); border-radius: 10px; margin-bottom: 8px; }
    .prediction-date { color: #aaa; font-size: 13px; }
    .prediction-amount { font-weight: 700; font-size: 18px; color: var(--primary); }
    .anomaly-alert { background: rgba(255, 170, 0, 0.15); border: 1px solid var(--warn); border-radius: 14px; padding: 12px; margin-bottom: 10px; display: flex; gap: 12px; align-items: center; }
    .anomaly-icon { font-size: 24px; flex-shrink: 0; }
    .anomaly-text { flex: 1; font-size: 13px; line-height: 1.4; }
    .stat-box { background: rgba(255,255,255,0.05); border-radius: 14px; padding: 16px; text-align: center; }
    .stat-value { font-size: 28px; font-weight: 800; margin-bottom: 4px; }
    .stat-label { font-size: 11px; color: #aaa; text-transform: uppercase; letter-spacing: 1px; }
    .complaint-template { background: rgba(255,255,255,0.03); border: 1px solid var(--border); border-radius: 14px; padding: 16px; margin-bottom: 12px; font-size: 13px; line-height: 1.6; color: #ddd; white-space: pre-wrap; max-height: 300px; overflow-y: auto; }
    .btn-group { display: flex; gap: 10px; margin-top: 10px; }
    .btn-small { flex: 1; padding: 12px; border-radius: 12px; border: none; font-weight: 600; font-size: 13px; cursor: pointer; transition: transform 0.1s; }
    .btn-small:active { transform: scale(0.96); }
    
    @keyframes fadeIn { from { opacity: 0; transform: translateY(-10px); } to { opacity: 1; transform: translateY(0); } }
    @keyframes coinFly { 0% { transform: translateY(0) rotate(0deg); opacity: 1; } 100% { transform: translateY(-300px) rotate(720deg); opacity: 0; } }
    @keyframes confetti { 0% { transform: translateY(0) rotate(0deg); opacity: 1; } 100% { transform: translateY(600px) rotate(360deg); opacity: 0; } }
    .coin { position: fixed; font-size: 40px; pointer-events: none; z-index: 9999; animation: coinFly 2s ease-out forwards; }
    .confetti-piece { position: fixed; width: 12px; height: 12px; pointer-events: none; z-index: 9999; animation: confetti 3s ease-out forwards; }
    .sarcasm-bubble { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background: rgba(0, 0, 0, 0.9); color: #fff; padding: 30px; border-radius: 20px; font-size: 20px; text-align: center; z-index: 9999; animation: fadeIn 0.3s, pulse 0.5s ease-in-out 3; max-width: 80%; box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5); line-height: 1.4; border: 1px solid var(--primary); }
    @keyframes pulse { 0%, 100% { transform: translate(-50%, -50%) scale(1); } 50% { transform: translate(-50%, -50%) scale(1.05); } }
    .meme-emoji { font-size: 60px; margin-bottom: 15px; animation: spin 0.5s ease-in-out; }
    @keyframes spin { from { transform: rotate(0deg); } to { transform: rotate(360deg); } }
    @keyframes pulse-glow { 0%, 100% { box-shadow: 0 10px 20px rgba(0,0,0,0.2), 0 0 0 0 var(--primary); transform: scale(1); } 50% { box-shadow: 0 10px 20px rgba(0,0,0,0.2), 0 0 20px var(--primary); transform: scale(1.02); } }
    .btn-check-pulse { animation: pulse-glow 2s infinite ease-in-out; }
    @keyframes slideInRight { from { transform: translateX(100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
    @keyframes slideInLeft { from { transform: translateX(-100%); opacity: 0; } to { transform: translateX(0); opacity: 1; } }
    @keyframes slideInUp { from { transform: translateY(50px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }
    @keyframes scaleIn { from { transform: scale(0.9); opacity: 0; } to { transform: scale(1); opacity: 1; } }
    .screen.anim-right { animation: slideInRight 0.4s cubic-bezier(0.22, 1, 0.36, 1); }
    .screen.anim-left { animation: slideInLeft 0.4s cubic-bezier(0.22, 1, 0.36, 1); }
    .screen.anim-up { animation: slideInUp 0.4s cubic-bezier(0.22, 1, 0.36, 1); }
    .screen.anim-scale { animation: scaleIn 0.3s cubic-bezier(0.22, 1, 0.36, 1); }
    @keyframes particle-float { 0% { transform: translate(0, 0) scale(1); opacity: 1; } 100% { transform: translate(var(--tx), var(--ty)) scale(0); opacity: 0; } }
    .particle { position: fixed; pointer-events: none; z-index: 9999; animation: particle-float 1.5s ease-out forwards; }
    @keyframes shake { 0%, 100% { transform: translateX(0); } 25% { transform: translateX(-5px); } 75% { transform: translateX(5px); } }
    @keyframes bounce { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-10px); } }

/* ================ НОВЫЕ МОДУЛИ ================ */

/* CINEMATIC ONBOARDING */
.cinematic-onboarding { position: fixed; inset: 0; z-index: 999999; background: #000; }
.onboarding-slide { width: 100%; height: 100vh; display: flex; flex-direction: column; align-items: center; justify-content: space-between; padding: 60px 20px; position: relative; overflow: hidden; }
.slide-background { position: absolute; inset: 0; z-index: 0; }
.particle-system { position: absolute; inset: 0; background-image: radial-gradient(2px 2px at 20px 30px, white, transparent), radial-gradient(2px 2px at 60px 70px, white, transparent), radial-gradient(1px 1px at 50px 50px, white, transparent); background-size: 200px 200px; animation: particle-float 20s linear infinite; }
@keyframes particle-float { from { transform: translateY(0); } to { transform: translateY(-200px); } }
.slide-content { z-index: 1; text-align: center; flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center; }
.slide-title { font-size: 36px; font-weight: 900; color: white; margin-bottom: 20px; text-shadow: 0 10px 30px rgba(0,0,0,0.5); }
.slide-subtitle { font-size: 18px; color: rgba(255,255,255,0.9); max-width: 600px; line-height: 1.6; }
.slide-navigation { z-index: 1; width: 100%; display: flex; flex-direction: column; align-items: center; gap: 30px; }
.progress-dots { display: flex; gap: 12px; }
.dot { width: 12px; height: 12px; border-radius: 50%; background: rgba(255,255,255,0.3); transition: all 0.3s; }
.dot.active { width: 30px; border-radius: 6px; background: white; }
.next-btn, .start-btn { padding: 18px 50px; border: none; border-radius: 50px; background: white; color: #667eea; font-size: 18px; font-weight: bold; cursor: pointer; transition: transform 0.2s; box-shadow: 0 10px 30px rgba(255,255,255,0.3); }
.start-btn { background: linear-gradient(135deg, #FFD700, #FFA500); color: black; box-shadow: 0 10px 30px rgba(255, 215, 0, 0.5); animation: pulse 2s infinite; }

/* NEURAL NETWORK DEMO */
.neural-net-demo { max-width: 500px; margin: 40px auto; }
.neural-svg { width: 100%; height: 200px; }
.neuron { fill: #667eea; stroke: white; stroke-width: 2; filter: drop-shadow(0 0 10px rgba(102, 126, 234, 0.8)); }
.prediction-output { background: rgba(255,255,255,0.1); padding: 20px; border-radius: 16px; margin-top: 20px; backdrop-filter: blur(10px); text-align: center; }
.prediction-value { font-size: 28px; font-weight: bold; color: #FFD700; margin: 10px 0; }
.prediction-confidence { color: #00B956; font-size: 16px; }

/* VOICE DEMO */
.voice-demo-widget { margin: 40px 0; }
.mic-button { width: 120px; height: 120px; border-radius: 50%; background: linear-gradient(135deg, #667eea, #764ba2); display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: transform 0.2s; box-shadow: 0 20px 60px rgba(102, 126, 234, 0.5); margin: 0 auto; }
.mic-button:active { transform: scale(0.95); }
.mic-icon { font-size: 48px; }
.tap-hint { color: white; font-size: 12px; opacity: 0.9; margin-top: 5px; }
.voice-demo-widget.listening .mic-button { animation: pulse-glow 1s infinite; }
@keyframes pulse-glow { 0%, 100% { box-shadow: 0 20px 60px rgba(102, 126, 234, 0.5); } 50% { box-shadow: 0 20px 100px rgba(102, 126, 234, 1); } }
.voice-response { background: rgba(0,0,0,0.5); padding: 20px; border-radius: 20px; backdrop-filter: blur(20px); text-align: center; }
.heard-text { font-size: 20px; color: #667eea; margin-bottom: 15px; }
.bot-response { font-size: 24px; font-weight: bold; color: #00B956; }

/* RECEIPT SCANNER */
.receipt-details-modal { position: fixed; inset: 0; background: rgba(0,0,0,0.9); display: flex; align-items: center; justify-content: center; z-index: 99999; padding: 20px; }
.receipt-paper { background: white; color: black; max-width: 400px; width: 100%; padding: 30px; border-radius: 12px; box-shadow: 0 20px 60px rgba(0,0,0,0.5); font-family: 'Courier New', monospace; }
.receipt-header { text-align: center; margin-bottom: 20px; border-bottom: 2px dashed #333; padding-bottom: 15px; }
.receipt-merchant { font-size: 20px; font-weight: bold; margin-bottom: 10px; }
.receipt-date { font-size: 14px; color: #666; }
.receipt-items { margin: 20px 0; }
.receipt-item { display: flex; justify-content: space-between; margin: 8px 0; font-size: 14px; }
.receipt-separator { border-top: 2px dashed #333; margin: 20px 0; }
.receipt-total { display: flex; justify-content: space-between; font-size: 20px; font-weight: bold; margin: 20px 0; }
.total-amount { color: #667eea; }

/* SMART WIDGETS */
.mini-widget { background: var(--glass); backdrop-filter: blur(20px); border: 1px solid var(--border); border-radius: 20px; padding: 20px; box-shadow: 0 10px 30px rgba(0,0,0,0.3); cursor: pointer; transition: transform 0.2s; }
.mini-widget:active { transform: scale(0.95); }
.balance-widget { text-align: center; min-width: 150px; }
.widget-icon { font-size: 36px; margin-bottom: 10px; }
.widget-value { font-size: 28px; font-weight: bold; color: #fff; }
.widget-label { font-size: 12px; color: #aaa; text-transform: uppercase; letter-spacing: 1px; margin-top: 5px; }
.widget-trend { font-size: 14px; font-weight: bold; margin-top: 10px; }
.widget-trend.up { color: #00B956; }
.widget-trend.down { color: #FF3333; }

/* COUNTDOWN WIDGET */
.countdown-widget { text-align: center; min-width: 180px; }
.countdown-circle { position: relative; width: 100px; height: 100px; margin: 0 auto 15px; }
.countdown-circle svg { width: 100%; height: 100%; }
.countdown-number { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-size: 32px; font-weight: bold; color: #667eea; }
.countdown-label { font-size: 12px; color: #aaa; }
.countdown-amount { font-size: 20px; font-weight: bold; color: #fff; margin-top: 10px; }

/* INSIGHTS TICKER */
.insights-ticker { background: rgba(102, 126, 234, 0.1); backdrop-filter: blur(10px); border-bottom: 1px solid var(--border); padding: 10px 0; overflow: hidden; }
.ticker-content { display: flex; animation: scroll-ticker 30s linear infinite; }
.ticker-item { display: flex; align-items: center; gap: 10px; padding: 0 30px; white-space: nowrap; }
.ticker-icon { font-size: 20px; }
.ticker-text { font-size: 14px; color: #fff; }
@keyframes scroll-ticker { from { transform: translateX(0); } to { transform: translateX(-50%); } }

/* QUICK ACTIONS PALETTE */
.quick-actions-palette { background: var(--glass); backdrop-filter: blur(30px); border: 1px solid var(--border); border-radius: 24px; padding: 24px; max-width: 400px; box-shadow: 0 20px 60px rgba(0,0,0,0.5); }
.palette-title { text-align: center; font-size: 18px; font-weight: bold; margin-bottom: 20px; color: #fff; }
.palette-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 15px; }
.palette-btn { background: rgba(255,255,255,0.05); border: 1px solid rgba(255,255,255,0.1); border-radius: 16px; padding: 20px 10px; display: flex; flex-direction: column; align-items: center; gap: 8px; cursor: pointer; transition: all 0.2s; }
.palette-btn:hover { background: rgba(255,255,255,0.1); transform: translateY(-2px); }
.palette-btn:active { transform: scale(0.95); }
.btn-icon { font-size: 32px; }
.btn-label { font-size: 11px; color: #aaa; text-align: center; }

/* FLOATING WIDGET CONTAINER */
.floating-widgets { position: fixed; bottom: 100px; right: 20px; z-index: 500; display: flex; flex-direction: column; gap: 15px; }
.widget-fab { width: 56px; height: 56px; border-radius: 50%; background: linear-gradient(135deg, var(--primary), #333); display: flex; align-items: center; justify-content: center; font-size: 22px; box-shadow: 0 5px 20px rgba(0,0,0,0.3); cursor: pointer; transition: transform 0.2s; border: none; }
.widget-fab:active { transform: scale(0.9); }

/* ADVISOR BOT */
.advisor-bubble { position: fixed; bottom: 180px; left: 20px; right: 20px; background: linear-gradient(135deg, rgba(102, 126, 234, 0.9), rgba(118, 75, 162, 0.9)); backdrop-filter: blur(20px); border-radius: 20px; padding: 20px; box-shadow: 0 10px 40px rgba(102, 126, 234, 0.4); animation: slideInUp 0.5s; z-index: 600; }
.advisor-header { display: flex; align-items: center; gap: 10px; margin-bottom: 10px; }
.advisor-avatar { font-size: 32px; }
.advisor-name { font-weight: bold; font-size: 14px; }
.advisor-message { font-size: 15px; line-height: 1.5; }
.advisor-actions { display: flex; gap: 10px; margin-top: 15px; }
.advisor-btn { flex: 1; padding: 10px; border-radius: 10px; border: none; font-weight: bold; cursor: pointer; }
.advisor-btn.primary { background: white; color: #667eea; }
.advisor-btn.secondary { background: rgba(255,255,255,0.2); color: white; }
@keyframes slideInUp { from { transform: translateY(100px); opacity: 0; } to { transform: translateY(0); opacity: 1; } }

/* THEME SPECIAL EFFECTS */
.stars { position: absolute; inset: 0; overflow: hidden; pointer-events: none; }
.star { position: absolute; width: 2px; height: 2px; background: white; border-radius: 50%; animation: twinkle 3s infinite; }
@keyframes twinkle { 0%, 100% { opacity: 0.3; } 50% { opacity: 1; } }

/* СТИЛИ ДЛЯ БУДИЛЬНИКА */
.day-selector {
    display: flex;
    justify-content: space-between;
    margin: 20px 0;
    gap: 5px;
}

.day-btn {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.2s;
    border: 1px solid transparent;
}

/* Активный день (выбранный) */
.day-btn.active {
    background: #00B956;
    color: white !important; /* !important перебивает красный цвет воскресенья */
    box-shadow: 0 0 10px rgba(0, 185, 86, 0.5);
    transform: scale(1.1);
}

/* === PRO WEATHER WIDGET (КАК НА СКРИНШОТЕ) === */
.weather-widget {
    /* Фон - имитация стекла и погоды */
    background: linear-gradient(to bottom, rgba(30, 40, 60, 0.6), rgba(10, 20, 30, 0.8));
    border-radius: 24px;
    padding: 20px;
    margin-bottom: 25px;
    backdrop-filter: blur(20px);
    -webkit-backdrop-filter: blur(20px);
    border: 1px solid rgba(255,255,255,0.1);
    box-shadow: 0 20px 50px rgba(0,0,0,0.4);
    color: white;
    font-family: 'SF Pro Display', sans-serif;
    overflow: hidden;
    position: relative;
    transition: background 1s ease;
}

/* Динамические цвета */
.weather-widget.sunny { background: linear-gradient(to bottom, rgba(50, 100, 200, 0.6), rgba(255, 150, 50, 0.4)); }
.weather-widget.rainy { background: linear-gradient(to bottom, rgba(30, 45, 60, 0.8), rgba(20, 30, 40, 0.9)); }

/* Верхняя часть: Температура и Иконка */
.weather-hero-section {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.weather-main-info {
    position: relative;
}

.weather-temp-huge {
    font-size: 72px;
    font-weight: 200; /* Тонкий шрифт как на скрине */
    line-height: 1;
    letter-spacing: -2px;
    text-shadow: 0 5px 20px rgba(0,0,0,0.3);
}

.weather-temp-unit {
    font-size: 24px;
    position: absolute;
    top: 10px;
    right: -20px;
    font-weight: 300;
}

.weather-main-icon {
    font-size: 64px;
    filter: drop-shadow(0 0 15px rgba(255,255,255,0.4));
}

.weather-desc-text {
    font-size: 16px;
    text-align: center;
    margin-bottom: 20px;
    font-weight: 500;
    opacity: 0.9;
    letter-spacing: 0.5px;
}

/* Сетка деталей (Влажность, Ветер и т.д.) */
.weather-details-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 8px 20px;
    font-size: 12px;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
}

.detail-item {
    display: flex;
    justify-content: space-between;
    color: rgba(255,255,255,0.7);
}

.detail-val {
    color: #fff;
    font-weight: 600;
}

/* Прогноз на неделю (Скролл) */
.weather-forecast-scroll {
    display: flex;
    overflow-x: auto;
    gap: 15px;
    padding-bottom: 5px;
    /* Скрываем скроллбар */
    scrollbar-width: none; 
}
.weather-forecast-scroll::-webkit-scrollbar { display: none; }

.forecast-day {
    display: flex;
    flex-direction: column;
    align-items: center;
    min-width: 50px;
    gap: 6px;
}

.f-day-name { 
    font-size: 11px; 
    font-weight: 700; 
    text-transform: uppercase; 
    background: rgba(255,165,0,0.2); 
    color: #FFAA00;
    padding: 2px 6px;
    border-radius: 4px;
}
.f-date { font-size: 10px; color: #aaa; }
.f-icon { font-size: 24px; margin: 4px 0; }
.f-high { font-size: 14px; font-weight: 700; color: #fff; }
.f-low { font-size: 12px; color: #aaa; }

/* Линия-разделитель в прогнозе (имитация графика) */
.forecast-bar {
    width: 2px;
    height: 30px;
    background: linear-gradient(to bottom, #FFAA00, #00B956);
    margin: 5px 0;
    opacity: 0.5;
    border-radius: 2px;
}

/* SYSTEM HUD */
.system-hud {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    margin-bottom: 20px;
}

.hud-box {
    background: rgba(0, 0, 0, 0.3);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 16px;
    padding: 12px;
    display: flex;
    align-items: center;
    gap: 10px;
    backdrop-filter: blur(5px);
}

.hud-icon {
    font-size: 24px;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.05);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hud-info {
    display: flex;
    flex-direction: column;
}

.hud-label {
    font-size: 10px;
    color: #888;
    text-transform: uppercase;
    font-weight: 700;
}

.hud-value {
    font-size: 16px;
    font-weight: 700;
    color: #fff;
}

.battery-level {
    width: 100%;
    height: 4px;
    background: #333;
    margin-top: 5px;
    border-radius: 2px;
    overflow: hidden;
}

.battery-fill {
    height: 100%;
    background: #00B956;
    width: 0%;
    transition: width 0.5s, background 0.5s;
}
.battery-fill.low { background: #ff3333; }
.battery-fill.charging { background: #FFD700; box-shadow: 0 0 10px #FFD700; }

/* ЭКРАН ЛОЖНОГО ВЫЗОВА */
#fake-call-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, #1c1c1e 0%, #000 100%); /* Темный фон iOS */
    /* Или можно поставить размытую картинку обоев */
    /* background: url('wallpaper.jpg') no-repeat center/cover; backdrop-filter: blur(10px); */
    z-index: 99999;
    display: none; /* Скрыто по умолчанию */
    flex-direction: column;
    justify-content: space-between;
    padding: 60px 30px 40px;
    color: white;
    text-align: center;
}

#fake-call-screen.active {
    display: flex;
    animation: fadeIn 0.5s;
}

.caller-info {
    margin-top: 40px;
}

.caller-name {
    font-size: 36px;
    font-weight: 400;
    margin-bottom: 10px;
}

.caller-status {
    font-size: 18px;
    color: rgba(255,255,255,0.6);
}

.call-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 50px;
}

.call-btn {
    width: 75px;
    height: 75px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    border: none;
    cursor: pointer;
    box-shadow: 0 10px 30px rgba(0,0,0,0.3);
}

.btn-decline {
    background: #ff3b30;
    color: white;
    animation: shake 2s infinite; /* Трясется для реализма */
}

.btn-accept {
    background: #34c759;
    color: white;
    animation: pulse 1.5s infinite;
}

.call-btn-label {
    margin-top: 10px;
    font-size: 14px;
    color: white;
    display: block;
}

/* NETSTALKER TERMINAL */
#netstalker-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.95);
    z-index: 100000;
    display: none;
    flex-direction: column;
    padding: 20px;
    font-family: 'Courier New', monospace;
    color: #00ff00;
    overflow: hidden;
}

.terminal-header {
    border-bottom: 1px solid #00ff00;
    padding-bottom: 10px;
    margin-bottom: 10px;
    display: flex;
    justify-content: space-between;
    font-weight: bold;
    text-shadow: 0 0 5px #00ff00;
}

.terminal-body {
    flex: 1;
    overflow-y: auto;
    font-size: 14px;
    line-height: 1.5;
}

.term-line {
    margin-bottom: 5px;
    opacity: 0;
    animation: typeIn 0.1s forwards;
}

.term-line.error { color: #ff3333; }
.term-line.warn { color: #FFAA00; }
.term-line.highlight { color: #fff; font-weight: bold; }

@keyframes typeIn { to { opacity: 1; } }

.close-term-btn {
    margin-top: 20px;
    background: transparent;
    border: 1px solid #00ff00;
    color: #00ff00;
    padding: 15px;
    font-family: 'Courier New', monospace;
    font-weight: bold;
    cursor: pointer;
    text-transform: uppercase;
}
.close-term-btn:active { background: #00ff00; color: black; }

/* ============ DIALER ============ */
.dialer-display {
    background: rgba(0,0,0,0.4);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 20px;
    min-height: 60px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 32px;
    font-weight: 300;
    letter-spacing: 2px;
    color: #fff;
    font-family: 'SF Mono', monospace;
}

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

.dialer-key {
    background: rgba(255,255,255,0.1);
    border: none;
    border-radius: 50%;
    width: 70px;
    height: 70px;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 28px;
    font-weight: 300;
    color: #fff;
    cursor: pointer;
    transition: all 0.15s;
}

.dialer-key:active {
    background: var(--primary);
    transform: scale(0.95);
}

.dialer-key span {
    font-size: 9px;
    color: #888;
    margin-top: 2px;
    letter-spacing: 1px;
}

.dialer-actions {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-top: 10px;
}

.dialer-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    font-size: 24px;
    cursor: pointer;
    transition: all 0.2s;
}

.dialer-btn.call {
    background: #4CAF50;
    width: 70px;
    height: 70px;
}

.dialer-btn.delete { background: rgba(255,255,255,0.1); }
.dialer-btn.clear { background: rgba(255,100,100,0.3); }
.dialer-btn:active { transform: scale(0.9); }

/* Контакты */
.contact-item {
    display: flex;
    align-items: center;
    padding: 12px;
    border-bottom: 1px solid var(--border);
    cursor: pointer;
    transition: background 0.2s;
}

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

.contact-avatar {
    width: 45px;
    height: 45px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--primary), #00bcd4);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    margin-right: 12px;
    color: #fff;
}

.contact-info { flex: 1; }
.contact-name { font-weight: 600; color: #fff; }
.contact-phone { font-size: 12px; color: #888; margin-top: 2px; }

.contact-call-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #4CAF50;
    border: none;
    font-size: 18px;
    cursor: pointer;
}