747 lines
13 KiB
CSS
747 lines
13 KiB
CSS
/* Header styles - matching admin.css for consistency */
|
|
.header {
|
|
background-color: var(--primary-color);
|
|
color: white;
|
|
padding: 15px 30px;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
box-shadow: 0 2px 4px rgba(0,0,0,0.1);
|
|
position: sticky;
|
|
top: 0;
|
|
z-index: 100;
|
|
width: 100%;
|
|
max-width: 100vw;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
.header h1 {
|
|
margin: 0;
|
|
font-size: 1.5em;
|
|
font-weight: 600;
|
|
flex: 1;
|
|
min-width: 0;
|
|
white-space: nowrap;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
}
|
|
|
|
.header-actions {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 20px;
|
|
flex-shrink: 0;
|
|
}
|
|
|
|
.user-info {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 10px;
|
|
color: rgba(255,255,255,0.9);
|
|
font-size: 14px;
|
|
}
|
|
|
|
.user-email {
|
|
font-weight: 500;
|
|
}
|
|
|
|
/* Mobile header adjustments */
|
|
@media (max-width: 768px) {
|
|
.header {
|
|
padding: 12px 15px;
|
|
}
|
|
|
|
.header h1 {
|
|
font-size: 1.2em;
|
|
}
|
|
|
|
.header-actions {
|
|
gap: 10px;
|
|
}
|
|
|
|
.user-info {
|
|
display: none; /* Hide user info on mobile to save space */
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.header {
|
|
padding: 10px 15px;
|
|
}
|
|
|
|
.header h1 {
|
|
font-size: 1.1em;
|
|
}
|
|
|
|
.header-actions .btn {
|
|
padding: 6px 12px;
|
|
font-size: 13px;
|
|
}
|
|
}
|
|
|
|
.shifts-container {
|
|
max-width: 1200px;
|
|
margin: 0 auto;
|
|
padding: 20px;
|
|
width: 100%;
|
|
box-sizing: border-box;
|
|
}
|
|
|
|
/* My Signups section - now at the top */
|
|
.my-signups {
|
|
margin-bottom: 40px;
|
|
padding-bottom: 30px;
|
|
border-bottom: 1px solid #e0e0e0;
|
|
}
|
|
|
|
.my-signups h2 {
|
|
margin-bottom: 20px;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.signup-item {
|
|
background: white;
|
|
border: 1px solid #e0e0e0;
|
|
border-radius: var(--border-radius);
|
|
padding: 15px;
|
|
margin-bottom: 10px;
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
}
|
|
|
|
.signup-item h4 {
|
|
margin: 0 0 5px 0;
|
|
}
|
|
|
|
.signup-item p {
|
|
margin: 0;
|
|
color: var(--secondary-color);
|
|
}
|
|
|
|
/* Filters section */
|
|
.shifts-filters {
|
|
margin-bottom: 30px;
|
|
}
|
|
|
|
.shifts-filters h2 {
|
|
margin-bottom: 15px;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.filter-group {
|
|
display: flex;
|
|
gap: 10px;
|
|
align-items: center;
|
|
margin-top: 10px;
|
|
}
|
|
|
|
.filter-group input {
|
|
padding: 8px 12px;
|
|
border: 1px solid #ddd;
|
|
border-radius: var(--border-radius);
|
|
}
|
|
|
|
/* Desktop: 3 columns layout */
|
|
.shifts-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(3, 1fr);
|
|
gap: 20px;
|
|
margin-bottom: 40px;
|
|
}
|
|
|
|
.shift-card {
|
|
background: white;
|
|
border: 1px solid #e0e0e0;
|
|
border-radius: var(--border-radius);
|
|
padding: 20px;
|
|
transition: var(--transition);
|
|
}
|
|
|
|
.shift-card:hover {
|
|
box-shadow: 0 4px 12px rgba(0,0,0,0.1);
|
|
}
|
|
|
|
.shift-card.full {
|
|
opacity: 0.7;
|
|
}
|
|
|
|
.shift-card.signed-up {
|
|
border-color: var(--success-color);
|
|
background-color: #f0f9ff;
|
|
}
|
|
|
|
.shift-card h3 {
|
|
margin: 0 0 15px 0;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.shift-details {
|
|
margin-bottom: 15px;
|
|
}
|
|
|
|
.shift-details p {
|
|
margin: 5px 0;
|
|
color: var(--secondary-color);
|
|
}
|
|
|
|
.shift-description {
|
|
margin: 15px 0;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.shift-actions {
|
|
margin-top: 15px;
|
|
display: flex;
|
|
gap: 10px;
|
|
flex-wrap: wrap;
|
|
align-items: center;
|
|
}
|
|
|
|
.no-shifts {
|
|
text-align: center;
|
|
color: var(--secondary-color);
|
|
padding: 40px;
|
|
grid-column: 1 / -1; /* Span all columns */
|
|
}
|
|
|
|
/* Calendar dropdown styles */
|
|
.calendar-dropdown {
|
|
position: relative;
|
|
display: inline-block;
|
|
z-index: 100; /* Lower than popup but above other content */
|
|
}
|
|
|
|
.calendar-toggle {
|
|
cursor: pointer;
|
|
position: relative;
|
|
}
|
|
|
|
.calendar-options {
|
|
position: absolute;
|
|
top: 100%;
|
|
left: 0;
|
|
min-width: 180px;
|
|
background: white;
|
|
border: 1px solid #e0e0e0;
|
|
border-radius: var(--border-radius);
|
|
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
|
z-index: 1000;
|
|
margin-top: 4px;
|
|
display: none; /* Hidden by default */
|
|
}
|
|
|
|
.calendar-option {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
padding: 10px 15px;
|
|
text-decoration: none;
|
|
color: var(--dark-color);
|
|
transition: var(--transition);
|
|
border-bottom: 1px solid #f0f0f0;
|
|
}
|
|
|
|
.calendar-option:last-child {
|
|
border-bottom: none;
|
|
}
|
|
|
|
.calendar-option:hover {
|
|
background-color: #f5f5f5;
|
|
}
|
|
|
|
.calendar-option img {
|
|
width: 16px;
|
|
height: 16px;
|
|
}
|
|
|
|
/* Ensure dropdowns appear above other elements */
|
|
.shift-card {
|
|
position: relative;
|
|
}
|
|
|
|
/* Update signup actions for My Shifts section */
|
|
.signup-actions {
|
|
display: flex;
|
|
gap: 10px;
|
|
align-items: center;
|
|
}
|
|
|
|
/* View toggle and calendar styles */
|
|
.shifts-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
margin-bottom: 15px;
|
|
}
|
|
|
|
.view-toggle {
|
|
display: flex;
|
|
gap: 5px;
|
|
}
|
|
|
|
.view-toggle .btn {
|
|
padding: 8px 15px;
|
|
}
|
|
|
|
.view-toggle .btn.active {
|
|
background-color: var(--primary-color);
|
|
color: white;
|
|
}
|
|
|
|
/* Calendar View Styles */
|
|
.calendar-view {
|
|
margin-bottom: 40px;
|
|
}
|
|
|
|
.calendar-header {
|
|
display: flex;
|
|
justify-content: space-between;
|
|
align-items: center;
|
|
margin-bottom: 20px;
|
|
padding: 0 10px;
|
|
}
|
|
|
|
.calendar-header h3 {
|
|
margin: 0;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.calendar-grid {
|
|
display: grid;
|
|
grid-template-columns: repeat(7, 1fr);
|
|
gap: 1px;
|
|
background-color: #e0e0e0;
|
|
border: 1px solid #e0e0e0;
|
|
border-radius: var(--border-radius);
|
|
overflow: hidden;
|
|
}
|
|
|
|
.calendar-day-header {
|
|
background-color: var(--primary-color);
|
|
color: white;
|
|
padding: 12px 8px;
|
|
text-align: center;
|
|
font-weight: bold;
|
|
font-size: 0.9em;
|
|
}
|
|
|
|
.calendar-day {
|
|
background-color: white;
|
|
min-height: 120px;
|
|
padding: 8px;
|
|
position: relative;
|
|
border: none;
|
|
display: flex;
|
|
flex-direction: column;
|
|
}
|
|
|
|
.calendar-day.other-month {
|
|
background-color: #f9f9f9;
|
|
color: #ccc;
|
|
}
|
|
|
|
.calendar-day.today {
|
|
background-color: #fff3cd;
|
|
}
|
|
|
|
.calendar-day-number {
|
|
font-size: 0.9em;
|
|
font-weight: bold;
|
|
margin-bottom: 5px;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.calendar-day.other-month .calendar-day-number {
|
|
color: #ccc;
|
|
}
|
|
|
|
.calendar-shifts {
|
|
display: flex;
|
|
flex-direction: column;
|
|
gap: 2px;
|
|
flex-grow: 1;
|
|
}
|
|
|
|
.calendar-shift {
|
|
background-color: var(--primary-color);
|
|
color: white;
|
|
padding: 2px 4px;
|
|
border-radius: 3px;
|
|
font-size: 0.75em;
|
|
cursor: pointer;
|
|
transition: var(--transition);
|
|
line-height: 1.2;
|
|
overflow: hidden;
|
|
text-overflow: ellipsis;
|
|
white-space: nowrap;
|
|
}
|
|
|
|
.calendar-shift:hover {
|
|
opacity: 0.8;
|
|
transform: scale(1.02);
|
|
}
|
|
|
|
.calendar-shift.my-shift {
|
|
background-color: var(--success-color);
|
|
}
|
|
|
|
.calendar-shift.full-shift {
|
|
background-color: var(--secondary-color);
|
|
}
|
|
|
|
.calendar-shift.available-shift {
|
|
background-color: var(--primary-color);
|
|
}
|
|
|
|
/* Calendar legend */
|
|
.calendar-legend {
|
|
display: flex;
|
|
justify-content: center;
|
|
gap: 20px;
|
|
margin-top: 20px;
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.legend-item {
|
|
display: flex;
|
|
align-items: center;
|
|
gap: 8px;
|
|
font-size: 0.9em;
|
|
}
|
|
|
|
.legend-color {
|
|
width: 16px;
|
|
height: 16px;
|
|
border-radius: 3px;
|
|
}
|
|
|
|
.legend-color.my-shift {
|
|
background-color: var(--success-color);
|
|
}
|
|
|
|
.legend-color.available-shift {
|
|
background-color: var(--primary-color);
|
|
}
|
|
|
|
.legend-color.full-shift {
|
|
background-color: var(--secondary-color);
|
|
}
|
|
|
|
/* Calendar shift popup/tooltip */
|
|
.shift-popup {
|
|
position: fixed; /* Changed from absolute to fixed */
|
|
background: white;
|
|
border: 1px solid #e0e0e0;
|
|
border-radius: var(--border-radius);
|
|
padding: 15px;
|
|
box-shadow: 0 4px 12px rgba(0,0,0,0.15);
|
|
z-index: 10000; /* High z-index to appear above header */
|
|
min-width: 250px;
|
|
max-width: 300px;
|
|
}
|
|
|
|
.shift-popup h4 {
|
|
margin: 0 0 10px 0;
|
|
color: var(--dark-color);
|
|
}
|
|
|
|
.shift-popup p {
|
|
margin: 5px 0;
|
|
color: var(--secondary-color);
|
|
}
|
|
|
|
.shift-popup .shift-actions {
|
|
margin-top: 10px;
|
|
display: flex;
|
|
gap: 10px;
|
|
}
|
|
|
|
/* Custom Confirmation Modal */
|
|
.confirm-modal {
|
|
position: fixed;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
z-index: 20000; /* Even higher than shift popup */
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
}
|
|
|
|
.confirm-modal-backdrop {
|
|
position: absolute;
|
|
top: 0;
|
|
left: 0;
|
|
right: 0;
|
|
bottom: 0;
|
|
background: rgba(0, 0, 0, 0.5);
|
|
display: flex;
|
|
align-items: center;
|
|
justify-content: center;
|
|
padding: 20px;
|
|
animation: fadeInBackdrop 0.2s ease-out;
|
|
}
|
|
|
|
.confirm-modal-content {
|
|
background: white;
|
|
border-radius: var(--border-radius);
|
|
box-shadow: 0 10px 25px rgba(0, 0, 0, 0.3);
|
|
max-width: 400px;
|
|
width: 100%;
|
|
padding: 30px;
|
|
text-align: center;
|
|
animation: slideInModal 0.3s ease-out;
|
|
position: relative;
|
|
}
|
|
|
|
.confirm-modal-content h3 {
|
|
margin: 0 0 15px 0;
|
|
color: var(--dark-color);
|
|
font-size: 1.2em;
|
|
}
|
|
|
|
.confirm-modal-content p {
|
|
margin: 0 0 25px 0;
|
|
color: var(--secondary-color);
|
|
line-height: 1.5;
|
|
}
|
|
|
|
.confirm-modal-actions {
|
|
display: flex;
|
|
gap: 15px;
|
|
justify-content: center;
|
|
}
|
|
|
|
.confirm-modal-actions .btn {
|
|
padding: 10px 20px;
|
|
font-weight: 500;
|
|
min-width: 100px;
|
|
}
|
|
|
|
/* Animations */
|
|
@keyframes fadeInBackdrop {
|
|
from {
|
|
opacity: 0;
|
|
}
|
|
to {
|
|
opacity: 1;
|
|
}
|
|
}
|
|
|
|
@keyframes slideInModal {
|
|
from {
|
|
opacity: 0;
|
|
transform: translate(-50%, -60%) scale(0.9);
|
|
}
|
|
to {
|
|
opacity: 1;
|
|
transform: translate(-50%, -50%) scale(1);
|
|
}
|
|
}
|
|
|
|
/* Position the modal content in the center */
|
|
.confirm-modal-content {
|
|
position: fixed;
|
|
top: 50%;
|
|
left: 50%;
|
|
transform: translate(-50%, -50%);
|
|
}
|
|
|
|
/* Mobile adjustments for confirm modal */
|
|
@media (max-width: 768px) {
|
|
.confirm-modal-backdrop {
|
|
padding: 15px;
|
|
}
|
|
|
|
.confirm-modal-content {
|
|
padding: 25px 20px;
|
|
max-width: 90%;
|
|
}
|
|
|
|
.confirm-modal-content h3 {
|
|
font-size: 1.1em;
|
|
}
|
|
|
|
.confirm-modal-actions {
|
|
flex-direction: column;
|
|
gap: 10px;
|
|
}
|
|
|
|
.confirm-modal-actions .btn {
|
|
width: 100%;
|
|
min-width: auto;
|
|
}
|
|
}
|
|
|
|
@media (max-width: 480px) {
|
|
.confirm-modal-content {
|
|
padding: 20px 15px;
|
|
}
|
|
|
|
.confirm-modal-content h3 {
|
|
font-size: 1em;
|
|
margin-bottom: 12px;
|
|
}
|
|
|
|
.confirm-modal-content p {
|
|
font-size: 0.9em;
|
|
margin-bottom: 20px;
|
|
}
|
|
}
|
|
|
|
/* Fix for mobile popup positioning */
|
|
@media (max-width: 768px) {
|
|
.shift-popup {
|
|
max-width: 90%;
|
|
left: 5% !important;
|
|
right: 5% !important;
|
|
width: auto;
|
|
position: fixed;
|
|
top: 50% !important;
|
|
transform: translateY(-50%);
|
|
}
|
|
}
|
|
|
|
/* Mobile adjustments */
|
|
@media (max-width: 768px) {
|
|
/* Ensure proper scrolling on mobile */
|
|
body {
|
|
overflow-y: auto;
|
|
}
|
|
|
|
#app {
|
|
overflow-y: auto;
|
|
}
|
|
|
|
.shifts-container {
|
|
padding: 15px;
|
|
padding-bottom: 60px; /* Add extra bottom padding for mobile */
|
|
}
|
|
|
|
.shifts-grid {
|
|
grid-template-columns: 1fr;
|
|
gap: 15px;
|
|
}
|
|
|
|
.signup-item {
|
|
flex-direction: column;
|
|
align-items: flex-start;
|
|
gap: 10px;
|
|
}
|
|
|
|
.signup-actions {
|
|
width: 100%;
|
|
justify-content: flex-start;
|
|
}
|
|
|
|
.shift-actions {
|
|
flex-direction: column;
|
|
width: 100%;
|
|
}
|
|
|
|
.shift-actions .btn,
|
|
.calendar-dropdown {
|
|
width: 100%;
|
|
}
|
|
|
|
.calendar-toggle {
|
|
width: 100%;
|
|
justify-content: center;
|
|
}
|
|
|
|
.calendar-options {
|
|
left: 0;
|
|
right: 0;
|
|
width: 100%;
|
|
}
|
|
|
|
.my-signups {
|
|
margin-bottom: 30px;
|
|
padding-bottom: 20px;
|
|
}
|
|
|
|
.shifts-filters {
|
|
margin-bottom: 20px;
|
|
}
|
|
|
|
.filter-group {
|
|
flex-wrap: wrap;
|
|
}
|
|
|
|
.shifts-header {
|
|
flex-direction: column;
|
|
align-items: stretch;
|
|
gap: 15px;
|
|
}
|
|
|
|
.view-toggle {
|
|
justify-content: center;
|
|
}
|
|
|
|
.calendar-day {
|
|
min-height: 80px;
|
|
padding: 4px;
|
|
}
|
|
|
|
.calendar-day-number {
|
|
font-size: 0.8em;
|
|
}
|
|
|
|
.calendar-shift {
|
|
font-size: 0.7em;
|
|
padding: 1px 2px;
|
|
}
|
|
|
|
.calendar-header {
|
|
padding: 0;
|
|
}
|
|
|
|
.calendar-header h3 {
|
|
font-size: 1.1em;
|
|
}
|
|
|
|
.calendar-legend {
|
|
gap: 15px;
|
|
}
|
|
|
|
.legend-item {
|
|
font-size: 0.8em;
|
|
}
|
|
|
|
.shift-popup {
|
|
max-width: 280px;
|
|
padding: 12px;
|
|
}
|
|
}
|
|
|
|
/* Extra small screens */
|
|
@media (max-width: 480px) {
|
|
.calendar-day {
|
|
min-height: 60px;
|
|
padding: 2px;
|
|
}
|
|
|
|
.calendar-shift {
|
|
font-size: 0.65em;
|
|
padding: 1px;
|
|
}
|
|
|
|
.calendar-day-number {
|
|
font-size: 0.75em;
|
|
}
|
|
}
|
|
|
|
/* Shifts Page Specific Overrides */
|
|
body {
|
|
height: auto;
|
|
min-height: 100vh;
|
|
min-height: var(--app-height);
|
|
}
|
|
|
|
#app {
|
|
height: auto;
|
|
min-height: 100vh;
|
|
min-height: var(--app-height);
|
|
} |