MediBot / app /globals.css
github-actions[bot]
Deploy MedOS Global from 0b9218f6
102e23b
@tailwind base;
@tailwind components;
@tailwind utilities;
/* ===== CSS Custom Properties ===== */
:root {
--vh: 1vh;
--color-bg-primary: #0f172a;
--color-bg-secondary: #1e293b;
--color-bg-tertiary: #334155;
--color-text-primary: #f8fafc;
--color-text-secondary: #94a3b8;
--color-accent: #3b82f6;
--color-accent-secondary: #10b981;
--color-danger: #ef4444;
--color-warning: #f59e0b;
--safe-area-top: env(safe-area-inset-top, 0px);
--safe-area-bottom: env(safe-area-inset-bottom, 0px);
--safe-area-left: env(safe-area-inset-left, 0px);
--safe-area-right: env(safe-area-inset-right, 0px);
}
/* ===== Base Styles ===== */
* {
box-sizing: border-box;
margin: 0;
padding: 0;
}
html {
-webkit-text-size-adjust: 100%;
-webkit-tap-highlight-color: transparent;
}
body {
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
'Helvetica Neue', Arial, sans-serif;
background-color: var(--color-bg-primary);
color: var(--color-text-primary);
overflow: hidden;
overscroll-behavior: none;
}
/* ===== Mobile Viewport Height Fix (iOS Safari) ===== */
.h-screen-safe {
height: calc(var(--vh, 1vh) * 100);
}
/* ===== Safe Area Padding ===== */
.pt-safe {
padding-top: var(--safe-area-top);
}
.pb-safe {
padding-bottom: var(--safe-area-bottom);
}
.pl-safe {
padding-left: var(--safe-area-left);
}
.pr-safe {
padding-right: var(--safe-area-right);
}
/* ===== Prevent Zoom on Input Focus (iOS) ===== */
input,
textarea,
select {
font-size: 16px !important;
}
/* ===== Touch Targets (Apple HIG: 44x44px minimum) ===== */
.touch-target {
min-height: 44px;
min-width: 44px;
display: flex;
align-items: center;
justify-content: center;
}
/* ===== Smooth Scrolling ===== */
.scroll-smooth {
-webkit-overflow-scrolling: touch;
scroll-behavior: smooth;
}
/* ===== Custom Scrollbar ===== */
::-webkit-scrollbar {
width: 6px;
height: 6px;
}
::-webkit-scrollbar-track {
background: transparent;
}
::-webkit-scrollbar-thumb {
background: #475569;
border-radius: 3px;
}
::-webkit-scrollbar-thumb:hover {
background: #64748b;
}
/* ===== Selection Style ===== */
::selection {
background-color: rgba(59, 130, 246, 0.3);
color: #f8fafc;
}
/* ===== RTL Support ===== */
[dir='rtl'] .sidebar-nav {
right: 0;
left: auto;
}
[dir='rtl'] .message-user {
margin-left: 0;
margin-right: auto;
}
[dir='rtl'] .message-bot {
margin-right: 0;
margin-left: auto;
}
[dir='rtl'] .chat-input-area {
flex-direction: row-reverse;
}
/* ===== Sidebar Menu Popup ===== */
.desktop-sidebar {
overflow: visible !important;
}
/* ===== Animation Utilities ===== */
.animate-delay-100 {
animation-delay: 100ms;
}
.animate-delay-200 {
animation-delay: 200ms;
}
.animate-delay-300 {
animation-delay: 300ms;
}
/* ===== Typing Indicator ===== */
.typing-dot {
width: 8px;
height: 8px;
border-radius: 50%;
background-color: #64748b;
animation: pulseDot 1.4s infinite ease-in-out both;
}
.typing-dot:nth-child(1) {
animation-delay: -0.32s;
}
.typing-dot:nth-child(2) {
animation-delay: -0.16s;
}
/* ===== Message Markdown Rendering ===== */
.message-content p {
margin-bottom: 0.5rem;
}
.message-content p:last-child {
margin-bottom: 0;
}
.message-content ul,
.message-content ol {
padding-left: 1.5rem;
margin-bottom: 0.5rem;
}
.message-content li {
margin-bottom: 0.25rem;
}
.message-content code {
background-color: rgba(71, 85, 105, 0.5);
padding: 0.125rem 0.375rem;
border-radius: 0.25rem;
font-size: 0.875rem;
}
.message-content pre {
background-color: rgba(15, 23, 42, 0.8);
padding: 0.75rem;
border-radius: 0.5rem;
overflow-x: auto;
margin-bottom: 0.5rem;
}
.message-content pre code {
background: none;
padding: 0;
}
.message-content strong {
font-weight: 600;
color: #f1f5f9;
}
.message-content h3,
.message-content h4 {
font-weight: 600;
margin-top: 0.75rem;
margin-bottom: 0.375rem;
}
/* ===== Swipe Sheet ===== */
.swipe-sheet {
transition: transform 0.3s cubic-bezier(0.32, 0.72, 0, 1);
will-change: transform;
}
/* ===== Bottom Navigation ===== */
.bottom-nav {
backdrop-filter: blur(12px);
-webkit-backdrop-filter: blur(12px);
background-color: rgba(15, 23, 42, 0.85);
}
/* ===== PWA Standalone Mode ===== */
@media all and (display-mode: standalone) {
body {
-webkit-user-select: none;
user-select: none;
}
.pwa-only {
display: block;
}
.browser-only {
display: none;
}
}
@media not all and (display-mode: standalone) {
.pwa-only {
display: none;
}
}
/* ===== Responsive Breakpoints ===== */
@media (max-width: 768px) {
.desktop-sidebar {
display: none;
}
.desktop-right-panel {
display: none;
}
.mobile-bottom-nav {
display: flex;
}
}
@media (min-width: 769px) {
.mobile-bottom-nav {
display: none;
}
.mobile-header-compact {
display: none;
}
}
/* ===== Emergency Pulse Animation ===== */
@keyframes emergencyPulse {
0%,
100% {
box-shadow: 0 0 0 0 rgba(239, 68, 68, 0.4);
}
50% {
box-shadow: 0 0 0 12px rgba(239, 68, 68, 0);
}
}
.emergency-pulse {
animation: emergencyPulse 2s infinite;
}
/* ===== Voice Recording Indicator ===== */
@keyframes voicePulse {
0%,
100% {
transform: scale(1);
opacity: 1;
}
50% {
transform: scale(1.2);
opacity: 0.7;
}
}
.voice-recording {
animation: voicePulse 1s infinite;
}