/* ================================================================ DENTAL IMAGE MANAGER - PREMIUM STYLES (Mobile-First) ================================================================ */ /* Fontes carregadas via no de cada página (evita o @import render-blocking, que serializa o download). */ :root { /* Premium Color Palette */ --primary-color: #4f46e5; /* Indigo 600 */ --primary-light: #6366f1; /* Indigo 500 */ --primary-dark: #4338ca; /* Indigo 700 */ --secondary-color: #ec4899; /* Pink 500 */ --success-color: #10b981; /* Emerald 500 */ --danger-color: #ef4444; /* Red 500 */ --warning-color: #f59e0b; /* Amber 500 */ --info-color: #3b82f6; /* Blue 500 */ /* Neutrals & Typography */ --dark-color: #0f172a; /* Slate 900 */ --text-primary: #1e293b; /* Slate 800 */ --text-secondary: #64748b; /* Slate 500 */ --text-muted: #94a3b8; /* Slate 400 */ /* Backgrounds & Borders */ --bg-color: #f8fafc; /* Slate 50 */ --bg-surface: #ffffff; --border-color: #e2e8f0; /* Slate 200 */ /* Shadows & Effects */ --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05); --shadow: 0 4px 6px -1px rgb(0 0 0 / 0.1), 0 2px 4px -2px rgb(0 0 0 / 0.1); --shadow-md: 0 10px 15px -3px rgb(0 0 0 / 0.1), 0 4px 6px -4px rgb(0 0 0 / 0.1); --shadow-lg: 0 20px 25px -5px rgb(0 0 0 / 0.1), 0 8px 10px -6px rgb(0 0 0 / 0.1); /* Glassmorphism */ --glass-bg: rgba(255, 255, 255, 0.7); --glass-border: rgba(255, 255, 255, 0.5); --glass-blur: blur(12px); /* Layout */ --radius-sm: 8px; --radius: 12px; --radius-lg: 20px; --radius-full: 9999px; --sidebar-width: 260px; --font-heading: 'Outfit', sans-serif; } * { margin: 0; padding: 0; box-sizing: border-box; -webkit-tap-highlight-color: transparent; } html { scroll-behavior: smooth; } body { font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif; background: var(--bg-color); color: var(--text-primary); line-height: 1.6; min-height: 100vh; -webkit-font-smoothing: antialiased; } /* ================================================================ LAYOUT & SIDEBAR (Premium Glassmorphism RF Dental) ================================================================ */ .app-container { display: flex; height: 100vh; width: 100vw; overflow: hidden; background: linear-gradient(135deg, #f8fafc 0%, #eff6ff 100%); } .sidebar { width: var(--sidebar-width); background: var(--glass-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); border-right: 1px solid var(--glass-border); display: flex; flex-direction: column; padding: 24px 0; z-index: 100; box-shadow: var(--shadow-md); flex-shrink: 0; transition: all 0.3s ease; } .sidebar-header { padding: 0 20px 16px; display: flex; align-items: center; gap: 12px; border-bottom: none; flex-shrink: 0; } .logo-icon { width: 40px; height: 40px; background: linear-gradient(135deg, #4cc9f0, var(--primary-color)); border-radius: 10px; display: flex; align-items: center; justify-content: center; font-size: 20px; color: white; } .sidebar-header h2 { font-family: var(--font-heading); font-size: 22px; font-weight: 600; letter-spacing: 0.5px; color: var(--dark-color); } .sidebar-nav { display: flex; flex-direction: column; gap: 2px; padding: 0 12px; flex: 1; overflow-y: auto; } .nav-item { padding: 8px 12px; border-radius: 8px; color: var(--dark-color); opacity: 0.7; text-decoration: none; font-weight: 500; font-size: 0.92rem; display: flex; align-items: center; gap: 10px; transition: all 0.3s ease; } .nav-item i { font-size: 18px; width: 20px; text-align: center; } .nav-item:hover { background: var(--bg-surface); color: var(--primary-color); opacity: 1; transform: translateX(4px); box-shadow: var(--shadow-sm); } .nav-item.active { background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%); color: white !important; opacity: 1; box-shadow: var(--shadow); font-weight: 600; } .sidebar-footer { border-top: 1px solid var(--border-color); margin-top: auto; padding: 6px 8px; flex-shrink: 0; } .logout-btn { width: 100%; padding: 6px 8px; background: transparent; border: 1px solid var(--glass-border); color: #a0aec0; border-radius: 6px; cursor: pointer; display: flex; align-items: center; justify-content: center; gap: 6px; font-family: 'Inter', sans-serif; font-weight: 500; font-size: 0.80rem; transition: all 0.3s; line-height: 1; } .logout-btn:hover { background: rgba(239, 68, 68, 0.15); color: var(--danger-color); border-color: var(--danger-color); } .nav-divider { height: 1px; background: var(--border-color); margin: 16px 0; } .nav-divider { height: 1px; background: var(--border-color); margin: 16px 0; } .client-filter { width: 100%; border: 1px solid var(--border-color); background: var(--bg-surface); color: var(--text-primary); border-radius: var(--radius-sm); padding: 10px 14px; font-family: inherit; font-size: 0.95rem; font-weight: 500; cursor: pointer; transition: all 0.2s ease; box-shadow: var(--shadow-sm); outline: none; } .client-filter:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15); } /* ================================================================ MAIN CONTENT & HEADER ================================================================ */ .main-content { flex: 1; display: flex; flex-direction: column; overflow: hidden; position: relative; } .header { background: var(--glass-bg); backdrop-filter: var(--glass-blur); -webkit-backdrop-filter: var(--glass-blur); border-bottom: 1px solid var(--glass-border); padding: 10px 24px; display: flex; justify-content: space-between; align-items: center; z-index: 90; box-shadow: var(--shadow-sm); flex-shrink: 0; } .header-left { display: flex; align-items: center; gap: 16px; } .header h1 { font-size: 1.5rem; font-weight: 700; color: var(--dark-color); letter-spacing: -0.5px; } .search-input { padding: 10px 16px; border: 1px solid var(--border-color); border-radius: var(--radius-full); font-size: 0.95rem; font-family: inherit; background: var(--bg-surface); color: var(--text-primary); width: 100%; min-width: 260px; box-shadow: var(--shadow-sm); transition: all 0.2s ease; outline: none; } .search-input:focus { border-color: var(--primary-color); box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15); transform: translateY(-1px); } .header-actions { display: flex; align-items: center; gap: 12px; } .content-scroll { flex: 1; overflow-y: auto; overflow-x: hidden; padding: 20px; } /* ================================================================ BUTTONS (Premium) ================================================================ */ .btn { padding: 10px 20px; border: none; border-radius: var(--radius-full); font-size: 0.95rem; font-weight: 600; font-family: inherit; cursor: pointer; transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1); white-space: nowrap; display: inline-flex; align-items: center; justify-content: center; gap: 8px; box-shadow: var(--shadow-sm); position: relative; overflow: hidden; } .btn::after { content: ''; position: absolute; top: 0; left: 0; width: 100%; height: 100%; background: linear-gradient(rgba(255,255,255,0.2), rgba(255,255,255,0)); opacity: 0; transition: opacity 0.2s; } .btn:hover::after { opacity: 1; } .btn:hover { transform: translateY(-2px); box-shadow: var(--shadow); } .btn:active { transform: translateY(0); } .btn-primary { background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%); color: white; } .btn-secondary { background: var(--bg-surface); color: var(--text-primary); border: 1px solid var(--border-color); } .btn-secondary:hover { background: #f1f5f9; border-color: #cbd5e1; } .btn-success { background: linear-gradient(135deg, var(--success-color) 0%, #059669 100%); color: white; } .btn-danger { background: linear-gradient(135deg, var(--danger-color) 0%, #dc2626 100%); color: white; } .btn-block { width: 100%; } .btn-back { background: var(--bg-surface); color: var(--text-secondary); border: 1px solid var(--border-color); padding: 8px 16px; } /* ================================================================ GRID & CARDS ================================================================ */ .images-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 24px; } .image-card, .patient-card { background: var(--bg-surface); border-radius: var(--radius-lg); overflow: hidden; box-shadow: var(--shadow); transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1); cursor: pointer; position: relative; border: 1px solid var(--glass-border); display: flex; flex-direction: column; } .image-card:hover, .patient-card:hover { transform: translateY(-6px); box-shadow: var(--shadow-lg); border-color: var(--primary-light); } .image-preview { width: 100%; height: 220px; object-fit: cover; background: #e2e8f0; position: relative; transition: transform 0.3s ease; } /* Miniatura como para permitir lazy-load nativo (loading="lazy"), preenchendo o .image-preview com o mesmo enquadramento do background anterior. */ .image-preview .preview-img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; display: block; } .preview-img-placeholder { position: absolute; inset: 0; width: 100%; height: 100%; background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%); display: flex; align-items: center; justify-content: center; color: #94a3b8; font-size: 40px; } .image-card:hover .image-preview { transform: scale(1.03); } .image-preview-wrapper { overflow: hidden; position: relative; } .image-info { padding: 20px; background: var(--bg-surface); position: relative; z-index: 2; } .image-patient-name { font-weight: 700; font-size: 1.1rem; color: var(--dark-color); margin-bottom: 4px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .image-meta { display: flex; justify-content: space-between; font-size: 0.85rem; color: var(--text-secondary); font-weight: 500; } .image-doctor-remark { margin-top: 12px; padding-top: 12px; border-top: 1px solid var(--border-color); font-size: 0.85rem; color: var(--text-muted); font-style: italic; } .delete-patient-btn { position: absolute; top: 12px; right: 12px; background: rgba(239, 68, 68, 0.9); backdrop-filter: blur(4px); color: white; border: none; border-radius: 50%; width: 36px; height: 36px; display: flex; align-items: center; justify-content: center; cursor: pointer; z-index: 10; transition: all 0.2s ease; box-shadow: var(--shadow-md); } .delete-patient-btn:hover { transform: scale(1.15) rotate(90deg); background: var(--danger-color); } /* ================================================================ MODALS (Premium Overlay) ================================================================ */ .modal { display: none; position: fixed; z-index: 1000; left: 0; top: 0; width: 100%; height: 100%; background: rgba(15, 23, 42, 0.6); backdrop-filter: blur(8px); -webkit-backdrop-filter: blur(8px); opacity: 0; transition: opacity 0.3s ease; } .modal.active { display: flex; align-items: center; justify-content: center; opacity: 1; } .modal-content { background: var(--bg-surface); border-radius: var(--radius-lg); width: 90%; height: 98vh; max-width: unset; max-height: unset; box-shadow: var(--shadow-lg); display: flex; flex-direction: column; transform: translateY(20px) scale(0.95); transition: all 0.3s cubic-bezier(0.34, 1.56, 0.64, 1); overflow: hidden; } .modal.active .modal-content { transform: translateY(0) scale(1); } .modal-large { width: 90%; height: 98vh; } .modal-header { padding: 24px 32px; border-bottom: 1px solid var(--border-color); display: flex; justify-content: space-between; align-items: center; background: var(--bg-surface); } .modal-header h2 { font-size: 1.4rem; font-weight: 700; color: var(--dark-color); } .modal-close { width: 36px; height: 36px; border-radius: 50%; background: var(--bg-color); display: flex; align-items: center; justify-content: center; font-size: 1.5rem; color: var(--text-secondary); cursor: pointer; transition: all 0.2s ease; } .modal-close:hover { background: #fee2e2; color: var(--danger-color); transform: rotate(90deg); } .modal-body { padding: 24px; overflow-y: auto; flex: 1; } /* ================================================================ FORMS & INPUTS ================================================================ */ .form-group { margin-bottom: 16px; } .form-group label { display: block; margin-bottom: 8px; font-weight: 600; font-size: 0.95rem; color: var(--text-primary); } .form-control, .form-group input, .form-group select, .form-group textarea { width: 100%; padding: 10px 12px; border: 2px solid var(--border-color); border-radius: var(--radius); font-size: 0.95rem; font-family: inherit; transition: all 0.2s ease; background: var(--bg-color); color: var(--text-primary); outline: none; } .form-control:focus, .form-group input:focus, .form-group select:focus, .form-group textarea:focus { border-color: var(--primary-color); background: var(--bg-surface); box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1); } /* ================================================================ NEW TRANSFORM LAYOUT (Editor de Imagens) ================================================================ */ .new-transform-layout { display: flex; gap: 24px; align-items: stretch; justify-content: center; padding: 16px 0; min-height: 400px; } @media (max-width: 768px) { .new-transform-layout { flex-direction: column; align-items: center; } } .transform-panel { flex: 1; background: var(--bg-surface); border: 2px solid var(--border-color); border-radius: var(--radius-lg); padding: 16px; display: flex; flex-direction: column; align-items: center; box-shadow: var(--shadow-sm); min-width: 0; /* allows flex shrinking properly */ max-width: 45%; } @media (max-width: 768px) { .transform-panel { max-width: 100%; width: 100%; } } .transform-panel.panel-preview { border-color: var(--primary-color); box-shadow: 0 0 0 4px rgba(79, 70, 229, 0.1); } .panel-title { font-size: 1rem; font-weight: 700; color: var(--text-secondary); margin-bottom: 16px; margin-top: 0; text-align: center; } .transform-panel .img-container { flex: 1; display: flex; align-items: center; justify-content: center; width: 100%; position: relative; } .transform-panel img { max-width: 100%; max-height: 350px; object-fit: contain; border-radius: var(--radius-sm); transition: transform 0.2s cubic-bezier(0.4, 0, 0.2, 1); } /* Sidebar Options */ .transform-sidebar { width: 80px; display: flex; flex-direction: column; align-items: center; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: var(--radius-full); padding: 16px 8px; box-shadow: var(--shadow-sm); flex-shrink: 0; } @media (max-width: 768px) { .transform-sidebar { width: 100%; flex-direction: row; border-radius: var(--radius-lg); justify-content: space-around; padding: 12px; } } .sidebar-title { font-size: 0.75rem; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); margin-bottom: 16px; margin-top: 0; } @media (max-width: 768px) { .sidebar-title { display: none; } } .sidebar-buttons { display: flex; flex-direction: column; gap: 12px; width: 100%; } @media (max-width: 768px) { .sidebar-buttons { flex-direction: row; justify-content: center; } } .sidebar-btn { display: flex; flex-direction: column; align-items: center; justify-content: center; width: 56px; height: 56px; border-radius: 50%; border: 1px solid var(--border-color); background: var(--bg-color); color: var(--text-primary); cursor: pointer; transition: all 0.2s ease; padding: 0; margin: 0 auto; } .sidebar-btn:hover { background: var(--primary-light); border-color: var(--primary-color); color: white; transform: translateY(-2px); } .sidebar-btn.active { background: var(--primary-color); border-color: var(--primary-dark); color: white; box-shadow: 0 4px 12px rgba(79, 70, 229, 0.3); } .sidebar-btn .icon { font-size: 1.2rem; margin-bottom: 2px; } .sidebar-btn .label { font-size: 0.65rem; font-weight: 600; line-height: 1; } /* ================================================================ TOAST NOTIFICATIONS ================================================================ */ .toast { position: fixed; bottom: 32px; right: 32px; padding: 16px 24px; border-radius: var(--radius-lg); color: white; font-weight: 600; font-size: 1rem; box-shadow: var(--shadow-lg); transform: translateY(100px); opacity: 0; transition: all 0.4s cubic-bezier(0.34, 1.56, 0.64, 1); z-index: 2000; display: flex; align-items: center; gap: 12px; } .toast.show { transform: translateY(0); opacity: 1; } .toast.success { background: linear-gradient(135deg, var(--success-color), #059669); } .toast.error { background: linear-gradient(135deg, var(--danger-color), #dc2626); } .toast.info { background: linear-gradient(135deg, var(--info-color), #2563eb); } .toast.warning { background: linear-gradient(135deg, var(--warning-color), #d97706); } /* ================================================================ NEW MODAL & SIDEBAR CLASSES ================================================================ */ .sidebar-filter-wrapper { padding: 10px 16px; } /* sidebar-footer definida acima, perto do .sidebar */ .sidebar-brand { display: flex; align-items: center; justify-content: space-between; opacity: 0.7; font-size: 0.85rem; font-weight: 600; } .version-badge { background: rgba(79, 70, 229, 0.1); color: var(--primary-color); padding: 2px 8px; border-radius: var(--radius-full); font-family: monospace; font-size: 0.75rem; } .modal-title-group { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; } .modal-actions-group { display: flex; gap: 8px; } .modal-actions-group .btn { width: 44px; height: 44px; padding: 0; font-size: 1.2rem; } .extra-info-panel { font-size: 0.95rem; color: var(--text-secondary); background: #f8f9fa; padding: 16px 24px; border-radius: var(--radius-sm); border: 1px solid var(--border-color); margin-bottom: 20px; } .transform-view-wrapper { display: flex; flex-direction: column; flex: 1; min-height: 0; height: 100%; } .transform-action-area { margin-top: 24px; background: #f8f9fa; padding: 24px; border-radius: var(--radius-sm); flex-shrink: 0; border: 1px solid var(--border-color); } .fine-tune-section { display: flex; flex-direction: column; align-items: center; margin-bottom: 24px; border-bottom: 1px solid var(--border-color); padding-bottom: 24px; } .fine-tune-title { font-weight: 700; font-size: 1rem; margin-bottom: 16px; color: var(--dark-color); display: flex; align-items: center; gap: 8px; } .fine-tune-controls { display: flex; align-items: center; gap: 12px; justify-content: center; flex-wrap: wrap; } .fine-tune-display { min-width: 100px; text-align: center; padding: 8px 16px; background: white; border: 1px solid var(--border-color); border-radius: var(--radius-sm); font-family: monospace; font-weight: 700; font-size: 1.2rem; color: var(--primary-color); } .btn-small { padding: 6px 12px; font-size: 0.85rem; } .form-actions-inline { display: flex; gap: 12px; margin-top: 16px; } .gto-create-section, .gto-link-section { background: #f8f9fa; padding: 20px; border-radius: var(--radius-sm); margin-bottom: 24px; border: 1px solid var(--border-color); } .gto-link-section { display: flex; align-items: center; justify-content: space-between; } .section-title { margin: 0; font-size: 1.1rem; color: var(--dark-color); } .gto-list-container { border: 1px solid var(--border-color); border-radius: var(--radius-sm); overflow: hidden; } /* ================================================================ UTILITIES & STATES ================================================================ */ .loading { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 60px 20px; color: var(--text-secondary); font-weight: 500; } .spinner { width: 48px; height: 48px; border: 4px solid var(--border-color); border-top: 4px solid var(--primary-color); border-radius: 50%; animation: spin 1s linear infinite; margin-bottom: 16px; } @keyframes spin { 0% { transform: rotate(0deg); } 100% { transform: rotate(360deg); } } .empty-state { text-align: center; padding: 80px 20px; color: var(--text-secondary); } .empty-icon { font-size: 4rem; margin-bottom: 24px; opacity: 0.5; } /* ================================================================ RESPONSIVE OVERRIDES ================================================================ */ @media (max-width: 768px) { .app-container { flex-direction: column; } .sidebar { width: 100%; height: auto; border-right: none; border-bottom: 1px solid var(--border-color); flex-direction: row; align-items: center; padding: 0 16px; } .sidebar-header { padding: 16px 0; border-bottom: none; } .sidebar-nav { flex-direction: row; overflow-x: auto; padding: 0 16px; gap: 16px; } .nav-item { padding: 12px; } .nav-item span:not(.icon) { display: none; } .content-scroll { padding: 16px; } .header { padding: 16px; flex-direction: column; gap: 16px; align-items: flex-start; } .search-input { min-width: 100%; } .modal-content { width: 90%; height: 98vh; } } /* RF Dental Premium Sidebar Menus Additions */ .nav-section-title { font-size: 10px; text-transform: uppercase; letter-spacing: 1.2px; font-weight: 700; color: var(--text-secondary); padding: 12px 16px 4px 16px; opacity: 0.6; } /* Ocultação inicial de elementos administrativos */ .admin-only { display: none !important; } /* Exibição quando autenticado como admin */ body.is-admin .admin-only { display: flex !important; flex-direction: column; gap: 8px; width: 100%; } /* Responsividade mobile para o agrupamento admin */ @media (max-width: 768px) { .nav-section-title { display: none !important; } body.is-admin .admin-only { display: flex !important; flex-direction: row !important; gap: 16px !important; width: auto; } } /* Versão do Sistema na Sidebar */ .system-version { text-align: center; font-size: 11px; color: var(--text-secondary); opacity: 0.5; margin-top: 12px; font-weight: 500; } @media (max-width: 768px) { .system-version { display: none !important; } } /* Wasabi Alert Banner */ .wasabi-alert-banner { background-color: #fee2e2; border-bottom: 1px solid #f87171; color: #991b1b; padding: 12px 24px; display: flex; align-items: center; gap: 16px; z-index: 10000; position: sticky; top: 0; width: 100%; box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1); } .wasabi-alert-icon { font-size: 24px; } .wasabi-alert-content { flex-grow: 1; font-size: 14px; line-height: 1.5; } .wasabi-alert-btn { background-color: #ef4444; color: white; border: none; padding: 8px 16px; border-radius: 6px; font-weight: 600; cursor: pointer; transition: background-color 0.2s; white-space: nowrap; } /* ================================================================ SYNC TABS & MODALS ================================================================ */ .sync-tabs { display: flex; gap: 8px; margin-bottom: 20px; border-bottom: 2px solid var(--border-color); padding-bottom: 12px; } .sync-tab-btn { padding: 10px 16px; background: transparent; border: none; border-radius: 8px; color: var(--text-secondary); font-weight: 600; cursor: pointer; transition: all 0.2s ease; font-size: 0.95rem; } .sync-tab-btn:hover { background: var(--bg-surface); color: var(--primary-color); } .sync-tab-btn.active { background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%); color: white; box-shadow: var(--shadow-sm); } .sync-tab-content { display: none; animation: fadeIn 0.3s ease; } .sync-tab-content.active { display: block; } .wasabi-alert-btn:hover { background-color: #dc2626; }