/* electron-responsive.css */
/* 2025-01-27: Responsive design for ElectronJS integration */

/* ElectronJS specific styles */
.electron-app {
    -webkit-app-region: no-drag;
    user-select: none;
    -webkit-user-select: none;
}

.electron-titlebar {
    -webkit-app-region: drag;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 10px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-weight: 600;
}

.electron-titlebar .title {
    font-size: 16px;
}

.electron-titlebar .controls {
    -webkit-app-region: no-drag;
    display: flex;
    gap: 10px;
}

.electron-titlebar .control-btn {
    width: 30px;
    height: 30px;
    border: none;
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border-radius: 4px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.electron-titlebar .control-btn:hover {
    background: rgba(255, 255, 255, 0.3);
}

.electron-titlebar .control-btn.close:hover {
    background: #e74c3c;
}

/* Responsive breakpoints for ElectronJS */
@media screen and (max-width: 1200px) {
    .electron-container {
        padding: 15px;
    }
    
    .auth-card,
    .profile-card,
    .wallet-card {
        max-width: 100%;
        margin: 10px;
        padding: 30px 20px;
    }
}

@media screen and (max-width: 768px) {
    .electron-container {
        padding: 10px;
    }
    
    .auth-card,
    .profile-card,
    .wallet-card {
        padding: 20px 15px;
        margin: 5px;
        border-radius: 15px;
    }
    
    .profile-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    .action-cards {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .action-buttons {
        flex-direction: column;
    }
    
    .action-buttons .btn {
        width: 100%;
        margin-bottom: 10px;
    }
    
    .balance-amount {
        font-size: 36px !important;
    }
    
    .profile-name {
        font-size: 24px !important;
    }
    
    .section-title {
        font-size: 18px !important;
    }
}

@media screen and (max-width: 480px) {
    .electron-container {
        padding: 5px;
    }
    
    .auth-card,
    .profile-card,
    .wallet-card {
        padding: 15px 10px;
        margin: 0;
        border-radius: 10px;
    }
    
    .profile-stats {
        grid-template-columns: 1fr;
        gap: 10px;
    }
    
    .stat-card {
        padding: 15px;
    }
    
    .balance-amount {
        font-size: 28px !important;
    }
    
    .profile-name {
        font-size: 20px !important;
    }
    
    .profile-avatar {
        width: 80px !important;
        height: 80px !important;
        font-size: 32px !important;
    }
    
    .form-floating {
        margin-bottom: 15px;
    }
    
    .form-control {
        padding: 10px 12px;
        font-size: 14px;
    }
    
    .btn {
        padding: 10px 16px;
        font-size: 14px;
    }
    
    .table-responsive {
        font-size: 12px;
    }
    
    .table th,
    .table td {
        padding: 8px;
    }
}

/* ElectronJS window controls */
.electron-window-controls {
    position: fixed;
    top: 0;
    right: 0;
    z-index: 10000;
    display: flex;
    background: rgba(0, 0, 0, 0.1);
    border-radius: 0 0 0 8px;
}

.electron-window-controls button {
    width: 40px;
    height: 30px;
    border: none;
    background: transparent;
    color: #666;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s ease;
}

.electron-window-controls button:hover {
    background: rgba(0, 0, 0, 0.1);
}

.electron-window-controls .close:hover {
    background: #e74c3c;
    color: white;
}

/* Dark mode support for ElectronJS */
@media (prefers-color-scheme: dark) {
    .electron-app {
        background: #1a1a1a;
        color: #ffffff;
    }
    
    .auth-card,
    .profile-card,
    .wallet-card {
        background: rgba(30, 30, 30, 0.95);
        color: #ffffff;
    }
    
    .form-control {
        background: #2a2a2a;
        border-color: #444;
        color: #ffffff;
    }
    
    .form-control:focus {
        background: #2a2a2a;
        border-color: #667eea;
        color: #ffffff;
    }
    
    .table {
        color: #ffffff;
    }
    
    .table th {
        background: #333;
        border-color: #444;
    }
    
    .table td {
        border-color: #444;
    }
    
    .stat-card {
        background: #2a2a2a;
        border-color: #444;
    }
}

/* Print styles for ElectronJS */
@media print {
    .electron-titlebar,
    .electron-window-controls,
    .navbar,
    .action-buttons,
    .btn {
        display: none !important;
    }
    
    .auth-card,
    .profile-card,
    .wallet-card {
        box-shadow: none;
        border: 1px solid #ccc;
        background: white !important;
        color: black !important;
    }
    
    .balance-card {
        background: #f8f9fa !important;
        color: black !important;
    }
}

/* High contrast mode for accessibility */
@media (prefers-contrast: high) {
    .auth-card,
    .profile-card,
    .wallet-card {
        border: 2px solid #000;
    }
    
    .btn-primary {
        background: #000;
        border: 2px solid #000;
    }
    
    .btn-primary:hover {
        background: #333;
        border-color: #333;
    }
    
    .form-control {
        border: 2px solid #000;
    }
    
    .form-control:focus {
        border-color: #000;
        box-shadow: 0 0 0 0.2rem rgba(0, 0, 0, 0.25);
    }
}

/* Reduced motion for accessibility */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .loading-spinner {
        animation: none !important;
    }
}

/* Focus indicators for keyboard navigation */
.btn:focus,
.form-control:focus,
.nav-link:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* ElectronJS specific animations */
.electron-fade-in {
    animation: electronFadeIn 0.3s ease-in-out;
}

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

.electron-slide-in {
    animation: electronSlideIn 0.3s ease-out;
}

@keyframes electronSlideIn {
    from {
        transform: translateX(-100%);
    }
    to {
        transform: translateX(0);
    }
}

/* ElectronJS notification styles */
.electron-notification {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10000;
    min-width: 300px;
    max-width: 400px;
    padding: 15px 20px;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: electronSlideIn 0.3s ease-out;
}

.electron-notification.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.electron-notification.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.electron-notification.warning {
    background: #fff3cd;
    color: #856404;
    border: 1px solid #ffeaa7;
}

.electron-notification.info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

/* ElectronJS loading overlay */
.electron-loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
}

.electron-loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #667eea;
    border-radius: 50%;
    animation: electronSpin 1s linear infinite;
}

@keyframes electronSpin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}
