160 lines
2.7 KiB
CSS
160 lines
2.7 KiB
CSS
.install-prompt {
|
|
position: fixed;
|
|
bottom: 1rem;
|
|
left: 1rem;
|
|
right: 1rem;
|
|
max-width: 400px;
|
|
margin: 0 auto;
|
|
background: white;
|
|
border-radius: 1rem;
|
|
padding: 1rem;
|
|
box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.05);
|
|
z-index: 1000;
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 0.75rem;
|
|
animation: slideUp 0.3s ease;
|
|
}
|
|
|
|
@keyframes slideUp {
|
|
from {
|
|
transform: translateY(100%);
|
|
opacity: 0;
|
|
}
|
|
to {
|
|
transform: translateY(0);
|
|
opacity: 1;
|
|
}
|
|
}
|
|
|
|
.install-content {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 0.75rem;
|
|
}
|
|
|
|
.install-icon {
|
|
font-size: 2rem;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.install-text {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 0.125rem;
|
|
}
|
|
|
|
.install-text strong {
|
|
color: #1e293b;
|
|
font-size: 1rem;
|
|
}
|
|
|
|
.install-text span {
|
|
color: #64748b;
|
|
font-size: 0.85rem;
|
|
}
|
|
|
|
.install-actions {
|
|
display: flex;
|
|
gap: 0.5rem;
|
|
justify-content: flex-end;
|
|
}
|
|
|
|
.install-dismiss {
|
|
background: transparent;
|
|
border: none;
|
|
color: #64748b;
|
|
padding: 0.5rem 1rem;
|
|
font-size: 0.9rem;
|
|
cursor: pointer;
|
|
border-radius: 0.5rem;
|
|
transition: all 0.2s;
|
|
}
|
|
|
|
.install-dismiss:hover {
|
|
background: #f1f5f9;
|
|
color: #1e293b;
|
|
}
|
|
|
|
.install-button {
|
|
background: linear-gradient(135deg, #6366f1 0%, #8b5cf6 100%);
|
|
color: white;
|
|
border: none;
|
|
padding: 0.5rem 1.25rem;
|
|
font-size: 0.9rem;
|
|
font-weight: 500;
|
|
cursor: pointer;
|
|
border-radius: 0.5rem;
|
|
transition: all 0.2s;
|
|
}
|
|
|
|
.install-button:hover {
|
|
transform: scale(1.02);
|
|
box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
|
|
}
|
|
|
|
/* Adjust for safe area on mobile */
|
|
@supports (padding-bottom: env(safe-area-inset-bottom)) {
|
|
.install-prompt {
|
|
bottom: calc(1rem + env(safe-area-inset-bottom));
|
|
}
|
|
}
|
|
|
|
/* Touch-friendly styles */
|
|
@media (hover: none), (pointer: coarse) {
|
|
.install-dismiss {
|
|
min-height: 44px;
|
|
padding: 0.625rem 1.25rem;
|
|
font-size: 0.95rem;
|
|
}
|
|
|
|
.install-button {
|
|
min-height: 44px;
|
|
padding: 0.625rem 1.5rem;
|
|
font-size: 0.95rem;
|
|
}
|
|
|
|
.install-actions {
|
|
gap: 0.75rem;
|
|
}
|
|
}
|
|
|
|
/* Active states for touch devices */
|
|
@media (hover: none) {
|
|
.install-dismiss:active {
|
|
background: #e2e8f0;
|
|
transform: scale(0.98);
|
|
}
|
|
|
|
.install-button:active {
|
|
transform: scale(0.98);
|
|
opacity: 0.9;
|
|
}
|
|
|
|
/* Disable iOS tap highlight */
|
|
.install-dismiss,
|
|
.install-button {
|
|
-webkit-tap-highlight-color: transparent;
|
|
}
|
|
}
|
|
|
|
/* Hover-only styles for desktop */
|
|
@media (hover: hover) {
|
|
.install-dismiss:hover {
|
|
background: #f1f5f9;
|
|
color: #1e293b;
|
|
}
|
|
|
|
.install-button:hover {
|
|
transform: scale(1.02);
|
|
box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
|
|
}
|
|
}
|
|
|
|
/* Focus states for accessibility */
|
|
.install-dismiss:focus-visible,
|
|
.install-button:focus-visible {
|
|
outline: 3px solid #6366f1;
|
|
outline-offset: 2px;
|
|
}
|