/* Launched Dashboard Styles */

.dashboard-main {
    padding: 20px;
    max-width: 1400px;
    margin: 0 auto;
}

.dashboard-container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 30px;
    min-height: calc(100vh - 120px);
}

.dashboard-left {
    display: flex;
    flex-direction: column;
}

.dashboard-right {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Calendar Styles - Copy from ongoing-rhythm.html */
.chapter-calendar-container {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    /* Remove flex: 1 to allow specific height control */
}

.calendar-title {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: bold;
    color: #AF232D;
    margin: 0 0 20px 0;
    border-bottom: 2px solid #AF232D;
    padding-bottom: 8px;
}

.calendar-nav {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
}

.calendar-nav-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 50%;
    width: 40px;
    height: 40px;
    font-size: 20px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s ease;
}

.calendar-nav-btn:hover {
    background: #8B1C24;
}

.calendar-month-title {
    font-family: 'Sentinel', serif;
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin: 0;
}

.calendar-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 1px;
    background: #ddd;
    border: 1px solid #ddd;
    border-radius: 8px;
    overflow: hidden;
}

.calendar-header {
    background: #f8f9fa;
    padding: 10px 5px;
    text-align: center;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    color: #666;
}

.calendar-day {
    background: white;
    min-height: 100px;
    width: 100%;
    max-width: 130px;
    padding: 8px 5px 5px 5px;
    cursor: pointer;
    position: relative;
    transition: background-color 0.2s ease;
    border: none;
    font-family: 'Sentinel', serif;
    box-sizing: border-box;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.calendar-day:hover {
    background: #f8f9fa;
}

.calendar-day.other-month {
    background: #f5f5f5;
    color: #ccc;
}

.calendar-day.today {
    background: #AF232D;
    color: white;
    border-radius: 8px;
}

.calendar-day.drag-over {
    background-color: rgba(175, 35, 45, 0.1);
    border: 2px dashed #AF232D;
    transform: scale(1.02);
    transition: all 0.2s ease;
}

.calendar-day.drag-over.other-month {
    background-color: rgba(175, 35, 45, 0.05);
    border: 2px dashed #AF232D;
}

.calendar-day-number {
    font-weight: bold;
    margin-bottom: 4px;
    flex-shrink: 0;
    text-align: left;
}

.calendar-events {
    display: flex;
    flex-direction: column;
    gap: 1px;
    flex-grow: 1;
}

.calendar-event {
    background: rgba(175, 35, 45, 0.1);
    border-left: 3px solid #AF232D;
    padding: 2px 4px;
    border-radius: 2px;
    font-size: 10px;
    line-height: 1.2;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    flex-shrink: 0;
    cursor: move;
    user-select: none;
    transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.calendar-event:hover {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.calendar-event.dragging {
    opacity: 0.5;
    transform: rotate(5deg);
    z-index: 1000;
}

.calendar-event.service { border-left-color: #8B4513; }
.calendar-event.fellowship { border-left-color: #FF4500; }
.calendar-event.altar-serving { border-left-color: #E5E5E5; }
.calendar-event.officer-meeting { border-left-color: #2F4F4F; }
.calendar-event.chapter-meeting { border-left-color: #DC143C; }
.calendar-event.retreat { border-left-color: #8A2BE2; }
.calendar-event.recruitment { border-left-color: #FF6347; }

.calendar-actions {
    display: flex;
    gap: 8px;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid #eee;
    justify-content: center;
}

.export-calendar-btn, .print-calendar-pdf-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 12px;
    font-family: 'Sentinel', serif;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.export-calendar-btn:hover, .print-calendar-pdf-btn:hover {
    background: #8B1C24;
}

/* Important Documents and Links Card */
.important-links-card {
    background: white;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    margin-top: 20px;
    position: relative;
}

.important-links-title {
    font-family: 'Sentinel', serif;
    font-size: 18px;
    font-weight: bold;
    color: #AF232D;
    margin: 0 0 15px 0;
    border-bottom: 2px solid #AF232D;
    padding-bottom: 8px;
}

.important-links-content {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 40px; /* Add space for upload button */
}

.important-link {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    color: #AF232D;
    text-decoration: none;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    transition: all 0.3s ease;
    cursor: pointer;
}

.important-link:hover {
    background: #f8f9fa;
    border-color: #AF232D;
    color: #8B1C24;
}

.upload-document-section {
    position: absolute;
    bottom: 15px;
    right: 15px;
}

.upload-document-btn {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: #AF232D;
    color: white;
    border: none;
    font-size: 20px;
    font-weight: bold;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.upload-document-btn:hover {
    background: #8B1C24;
    transform: scale(1.1);
}



/* Communication Center Styles */
.communication-center {
    background: white;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    flex: 1;
}

.communication-center-title {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: bold;
    color: #AF232D;
    margin: 0 0 20px 0;
    border-bottom: 2px solid #AF232D;
    padding-bottom: 8px;
}

.communication-toggle {
    margin-bottom: 20px;
}

.toggle-container {
    position: relative;
    display: inline-flex;
    background: #f0f0f0;
    border-radius: 20px;
    padding: 4px;
    margin-bottom: 20px;
}

.toggle-option {
    padding: 8px 16px;
    border-radius: 16px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    z-index: 2;
    position: relative;
    color: #666;
}

.toggle-option.active {
    color: white;
}

.toggle-slider {
    position: absolute;
    top: 4px;
    left: 4px;
    width: calc(50% - 4px);
    height: calc(100% - 8px);
    background: #AF232D;
    border-radius: 16px;
    transition: transform 0.3s ease;
    z-index: 1;
}

.toggle-slider.sms-active {
    transform: translateX(100%);
}

.communication-form {
    display: block;
}

.form-group {
    margin-bottom: 15px;
}

.form-group label {
    display: block;
    margin-bottom: 5px;
    font-family: 'Sentinel', serif;
    font-weight: 500;
    color: #333;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    box-sizing: border-box;
}

.recipients-section {
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 10px;
}

.recipient-groups {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 10px;
}

.recipient-group-btn {
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 6px 12px;
    font-family: 'Sentinel', serif;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.recipient-group-btn:hover {
    background: #e9ecef;
}

.recipient-group-btn.active {
    background: #AF232D;
    color: white;
    border-color: #AF232D;
}

.recipient-count {
    font-size: 12px;
    color: #666;
    font-style: italic;
}

/* Recipient count badges on buttons */
.recipient-count-badge {
    display: inline-block;
    font-size: 11px;
    font-weight: 600;
    opacity: 0.85;
    margin-left: 3px;
}

.recipient-group-btn.active .recipient-count-badge,
.recipient-group-btn.selected .recipient-count-badge {
    opacity: 1;
}

.email-editor {
    min-height: 150px;
    max-height: 300px;
    overflow-y: auto;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    line-height: 1.5;
}

.send-email-btn, .send-sms-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.send-email-btn:hover, .send-sms-btn:hover {
    background: #8B1C24;
}

.send-email-btn:disabled, .send-sms-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.recipient-group-btn.selected {
    background-color: #AF232D;
    color: white;
    border-color: #AF232D;
}

.sms-textarea {
    resize: vertical;
    min-height: 100px;
}

.sms-info {
    display: flex;
    justify-content: space-between;
    font-size: 12px;
    color: #666;
    margin-top: 5px;
}

.phone-number-warning {
    background: #d1ecf1;
    border: 1px solid #bee5eb;
    border-radius: 4px;
    padding: 8px;
    margin-bottom: 10px;
}

.warning-text {
    font-size: 12px;
    color: #0c5460;
}

.sms-reply-info {
    background: #fff3cd;
    border: 1px solid #ffeaa7;
    border-radius: 4px;
    padding: 8px;
    margin-bottom: 10px;
}

.info-text {
    font-size: 12px;
    color: #856404;
}

.test-sms-btn {
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-family: 'Sentinel', serif;
    font-size: 12px;
    cursor: pointer;
    margin-right: 10px;
    margin-bottom: 10px;
}

.test-sms-btn:hover {
    background: #5a6268;
}

.email-history, .sms-history {
    margin-top: 20px;
    border-top: 1px solid #eee;
    padding-top: 15px;
}

.email-history h4, .sms-history h4 {
    font-family: 'Sentinel', serif;
    color: #AF232D;
    margin-bottom: 10px;
    font-size: 16px;
}

.email-history-list, .sms-history-list {
    max-height: 200px;
    overflow-y: auto;
}

.email-history-item, .sms-history-item {
    background: white;
    border-radius: 4px;
    padding: 12px;
    margin-bottom: 10px;
    border-left: 3px solid #AF232D;
}

.email-history-header, .sms-history-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 8px;
}

.email-history-subject, .sms-history-preview {
    font-family: 'Sentinel', serif;
    font-weight: 500;
    color: #333;
    font-size: 14px;
    margin: 0;
}

.email-history-date, .sms-history-date {
    font-size: 11px;
    color: #666;
}

.email-history-sender {
    font-size: 12px;
    color: #AF232D;
    margin-bottom: 4px;
}

.email-history-recipients, .sms-history-recipients {
    font-size: 11px;
    color: #666;
}

.email-history-attachments {
    font-size: 11px;
    color: #999;
    margin-top: 4px;
}

/* Upload Card Styles */
.upload-card {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.meeting-minutes-toggle {
    margin-bottom: 20px;
}

.meeting-minutes-upload {
    margin-bottom: 20px;
    padding: 15px;
    background: white;
    border-radius: 4px;
    border: 1px solid #ddd;
}

.meeting-minutes-form .form-group {
    margin-bottom: 12px;
}

.upload-minutes-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.upload-minutes-btn:hover {
    background: #8B1C24;
}

.upload-minutes-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

.download-btn {
    background: #AF232D;
    color: #fff;
    border: none;
    border-radius: 4px;
    padding: 8px 16px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s ease, transform 0.1s ease;
}

.download-btn:hover {
    background: #8B1C24;
}

.download-btn:active {
    transform: translateY(1px);
}

.meeting-minutes-list {
    max-height: 300px;
    overflow-y: auto;
}

/* Tabs (home + dashboard) */
.dashboard-tabs {
    display: flex;
    gap: 10px;
    padding: 0 20px 10px 20px;
    flex-wrap: wrap;
}
.tab-btn {
    border: 1px solid #AF232D;
    background: #fff;
    color: #AF232D;
    padding: 10px 16px;
    border-radius: 6px;
    font-weight: 600;
    font-family: 'Sentinel', serif;
    cursor: pointer;
    transition: all 0.2s ease;
}
.tab-btn:hover {
    background: #f8dfe2;
}
.tab-btn.active {
    background: #AF232D;
    color: #fff;
}

/* Stage Carousel */
.stage-carousel {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 12px;
    padding: 20px;
    background: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    margin-bottom: 20px;
    position: relative;
    overflow: visible;
}

/* Progress Carousel Toggle for launched dashboard */
#progress-carousel-container {
    position: relative;
    transition: all 0.3s ease;
}

#progress-carousel-container.hidden {
    display: none;
}

.carousel-toggle-btn {
    position: absolute;
    top: 8px;
    right: 12px;
    background: rgba(175, 35, 45, 0.08);
    border: 1px solid rgba(175, 35, 45, 0.2);
    border-radius: 6px;
    padding: 6px 10px;
    cursor: pointer;
    color: #AF232D;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 4px;
    font-size: 12px;
    font-family: 'Sentinel', serif;
    z-index: 10;
}

.carousel-toggle-btn:hover {
    background: rgba(175, 35, 45, 0.15);
    border-color: rgba(175, 35, 45, 0.4);
}

.collapsed-carousel-bar {
    display: flex;
    justify-content: center;
    padding: 8px 20px;
    background: linear-gradient(to bottom, #f8f8f8, #fff);
    border-bottom: 1px solid #eee;
}

.show-carousel-btn {
    background: transparent;
    border: 1px dashed rgba(175, 35, 45, 0.3);
    border-radius: 20px;
    padding: 6px 16px;
    cursor: pointer;
    color: #AF232D;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    font-size: 13px;
    font-family: 'Sentinel', serif;
    font-weight: 500;
}

.show-carousel-btn:hover {
    background: rgba(175, 35, 45, 0.05);
    border-color: rgba(175, 35, 45, 0.5);
    border-style: solid;
}

.stage-carousel-track {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: transform 0.4s ease;
}

.stage-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    padding: 12px 16px;
    text-decoration: none;
    color: inherit;
    border-radius: 12px;
    transition: all 0.4s ease;
    position: relative;
    min-width: 100px;
    background: transparent;
}

.stage-card-icon {
    width: 64px;
    height: 64px;
    object-fit: contain;
    transition: all 0.4s ease;
}

.stage-card-label {
    font-size: 11px;
    font-weight: 600;
    color: #666;
    text-align: center;
    max-width: 90px;
    line-height: 1.2;
    transition: all 0.4s ease;
}

.stage-card-check {
    position: absolute;
    top: 8px;
    right: 8px;
    font-size: 14px;
    color: #28a745;
    opacity: 0;
    transition: opacity 0.3s ease;
}

/* Completed stages show checkmark */
.stage-card.completed .stage-card-check {
    opacity: 1;
}

/* Active/Current stage - prominent */
.stage-card.active {
    transform: scale(1.15);
    z-index: 10;
    background: rgba(175, 35, 45, 0.08);
}

.stage-card.active .stage-card-icon {
    width: 80px;
    height: 80px;
}

.stage-card.active .stage-card-label {
    font-size: 13px;
    color: #AF232D;
    font-weight: 700;
}

/* Adjacent stages - slightly faded */
.stage-card.adjacent {
    opacity: 0.6;
    transform: scale(0.9);
}

/* Far stages - more faded */
.stage-card.far {
    opacity: 0.35;
    transform: scale(0.8);
}

/* Hover effect for clickable stages */
.stage-card:hover {
    opacity: 1 !important;
    transform: scale(1.05);
    background: rgba(175, 35, 45, 0.05);
}

.stage-card.active:hover {
    transform: scale(1.18);
}

.stage-nav-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: #AF232D;
    color: white;
    border: none;
    font-size: 20px;
    cursor: pointer;
    transition: all 0.2s;
    flex-shrink: 0;
    z-index: 20;
}

.stage-nav-btn:hover {
    background: #8B1C24;
    transform: scale(1.1);
}

.stage-nav-btn:disabled {
    background: #ddd;
    color: #999;
    cursor: not-allowed;
    transform: none;
}

.stage-congrats {
    position: absolute;
    bottom: 5px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 12px;
    color: #28a745;
    font-weight: 600;
    white-space: nowrap;
}

/* Mobile responsive */
@media (max-width: 600px) {
    .stage-carousel {
        padding: 12px 8px;
    }
    
    .stage-card-icon {
        width: 48px;
        height: 48px;
    }
    
    .stage-card.active .stage-card-icon {
        width: 64px;
        height: 64px;
    }
    
    .stage-card-label {
        font-size: 9px;
        max-width: 70px;
    }
    
    .stage-card.active .stage-card-label {
        font-size: 11px;
    }
    
    .stage-nav-btn {
        width: 30px;
        height: 30px;
        font-size: 16px;
    }
}

/* Legacy - keep for compatibility */
.stage-banner {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 16px;
    padding: 12px 20px;
    background: #ffffff;
    border-bottom: 1px solid #e5e5e5;
    text-align: center;
    margin-bottom: 20px;
}

.stage-banner-icon {
    width: 96px;
    height: 96px;
    object-fit: contain;
}

.stage-banner-text {
    display: flex;
    flex-direction: column;
    gap: 6px;
    align-items: center;
}

.stage-status-text {
    font-weight: 700;
    color: #AF232D;
    font-size: 18px;
}

.roster-inline-card {
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    padding: 16px;
    margin-bottom: 16px;
}

.roster-inline-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.roster-inline-header h3 {
    margin: 0;
    color: #AF232D;
}

.roster-inline-status {
    font-size: 13px;
    color: #666;
}

.inline-link {
    color: #AF232D;
    font-weight: 600;
    text-decoration: none;
}

.inline-link:hover {
    text-decoration: underline;
}

.meeting-minutes-item {
    background: white;
    border-radius: 4px;
    padding: 12px;
    margin-bottom: 10px;
    border-left: 3px solid #AF232D;
}

.meeting-minutes-title {
    font-family: 'Sentinel', serif;
    font-weight: 500;
    color: #AF232D;
    text-decoration: none;
    font-size: 14px;
}

.meeting-minutes-title:hover {
    text-decoration: underline;
}

.meeting-minutes-meta {
    font-size: 12px;
    color: #666;
    margin-top: 4px;
}

.meeting-minutes-uploader {
    font-size: 11px;
    color: #999;
    margin-top: 2px;
}

.no-meeting-minutes {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 20px;
}

.success-message {
    color: #155724;
    background-color: #d4edda;
    border: 1px solid #c3e6cb;
    padding: 8px 12px;
    border-radius: 4px;
    margin-top: 10px;
}

.error-message {
    color: #721c24;
    background-color: #f8d7da;
    border: 1px solid #f5c6cb;
    padding: 8px 12px;
    border-radius: 4px;
    margin-top: 10px;
}

/* Event Modal Styles */
.event-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

/* Email Detail Modal Styles */
.email-detail-modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.email-detail-modal-content {
    position: relative;
    background-color: white;
    margin: 2% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
}

.email-detail-header {
    background: #f8f9fa;
    padding: 20px;
    border-bottom: 1px solid #dee2e6;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    flex-shrink: 0;
}

.email-detail-header h3 {
    font-family: 'Sentinel', serif;
    color: #AF232D;
    margin: 0;
    font-size: 18px;
    font-weight: 500;
    flex: 1;
    margin-right: 15px;
    line-height: 1.3;
}

.email-detail-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
}

.email-action-btn {
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 6px 12px;
    font-family: 'Sentinel', serif;
    font-size: 12px;
    cursor: pointer;
    transition: background-color 0.3s ease;
    display: flex;
    align-items: center;
    gap: 4px;
}

.email-action-btn:hover {
    background: #5a6268;
}

.email-close-btn {
    background: none;
    border: none;
    font-size: 24px;
    color: #6c757d;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background-color 0.3s ease;
}

.email-close-btn:hover {
    background: rgba(0, 0, 0, 0.1);
}

.email-detail-meta {
    padding: 20px;
    border-bottom: 1px solid #eee;
    background: white;
    flex-shrink: 0;
}

.email-meta-row {
    display: flex;
    margin-bottom: 8px;
    font-size: 14px;
}

.email-meta-row:last-child {
    margin-bottom: 0;
}

.email-meta-label {
    font-family: 'Sentinel', serif;
    font-weight: 500;
    color: #666;
    min-width: 80px;
    flex-shrink: 0;
}

.email-detail-content {
    flex: 1;
    overflow-y: auto;
    position: relative;
}

.email-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
}

.loading-spinner {
    width: 32px;
    height: 32px;
    border: 3px solid #f3f3f3;
    border-top: 3px solid #AF232D;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 15px;
}

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

.email-loading p {
    color: #666;
    font-family: 'Sentinel', serif;
    margin: 0;
}

.email-content-body {
    padding: 20px;
    font-family: 'Sentinel', serif;
    line-height: 1.6;
    color: #333;
}

.email-content-body h1,
.email-content-body h2,
.email-content-body h3,
.email-content-body h4,
.email-content-body h5,
.email-content-body h6 {
    font-family: 'Sentinel', serif;
    color: #AF232D;
    margin-top: 20px;
    margin-bottom: 10px;
}

.email-content-body p {
    margin-bottom: 12px;
}

.email-content-body ul,
.email-content-body ol {
    margin-bottom: 12px;
    padding-left: 25px;
}

.email-content-body blockquote {
    border-left: 4px solid #AF232D;
    padding-left: 15px;
    margin: 15px 0;
    font-style: italic;
    color: #666;
}

.email-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px;
    text-align: center;
}

.email-error p {
    color: #666;
    font-family: 'Sentinel', serif;
    margin: 0;
}

.email-detail-attachments {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.attachment-item {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    background: #f8f9fa;
    border-radius: 4px;
    font-size: 13px;
}

.attachment-icon {
    font-size: 16px;
}

.attachment-info {
    flex: 1;
}

.attachment-name {
    font-weight: 500;
    color: #333;
}

.attachment-size {
    color: #666;
    font-size: 11px;
}

/* Mobile responsiveness for email modal */
@media (max-width: 768px) {
    .email-detail-modal-content {
        margin: 5% auto;
        width: 95%;
        max-height: 90vh;
    }
    
    .email-detail-header {
        padding: 15px;
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
    }
    
    .email-detail-header h3 {
        margin-right: 0;
        margin-bottom: 10px;
    }
    
    .email-detail-actions {
        justify-content: space-between;
    }
    
    .email-detail-meta {
        padding: 15px;
    }
    
    .email-meta-row {
        flex-direction: column;
        gap: 4px;
        margin-bottom: 12px;
    }
    
    .email-meta-label {
        min-width: auto;
        font-weight: 600;
    }
    
    .email-content-body {
        padding: 15px;
    }
}

.event-modal-content {
    background: white;
    margin: 5% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

@keyframes modalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.event-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px 15px 25px;
    border-bottom: 1px solid #eee;
}

.event-modal-header h3 {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: 500;
    color: #AF232D;
    margin: 0;
}

.close-modal-btn {
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    padding: 0;
    line-height: 1;
    transition: color 0.2s ease;
}

.close-modal-btn:hover {
    color: #AF232D;
}

.event-form {
    padding: 20px 25px;
}

.event-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 20px;
    margin-bottom: 25px;
}

.event-form-group {
    display: flex;
    flex-direction: column;
}

.event-form-group-full {
    grid-column: 1 / -1;
}

.event-form-group label {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 6px;
}

.event-form-group input,
.event-form-group select,
.event-form-group textarea {
    padding: 10px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    background: white;
    transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.event-form-group input:focus,
.event-form-group select:focus,
.event-form-group textarea:focus {
    outline: none;
    border-color: #AF232D;
    box-shadow: 0 0 0 3px rgba(175, 35, 45, 0.1);
}

.event-form-group textarea {
    resize: vertical;
    min-height: 80px;
}

.recurring-label {
    display: flex !important;
    flex-direction: row !important;
    align-items: center;
    gap: 8px;
    cursor: pointer;
    font-size: 14px !important;
}

.recurring-label input[type="checkbox"] {
    width: auto !important;
    margin: 0 !important;
}

.recurring-options {
    margin-top: 10px;
}

.recurring-options select {
    width: 100%;
}

.event-modal-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.event-modal-actions-right {
    display: flex;
    gap: 12px;
}

.save-event-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.save-event-btn:hover {
    background: #8B1C24;
}

.cancel-event-btn {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.cancel-event-btn:hover {
    background: #e9ecef;
}

.delete-event-btn {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.delete-event-btn:hover {
    background: #c82333;
}

/* Delete Modal Styles */
.delete-modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    animation: modalSlideIn 0.3s ease-out;
}

.delete-modal-content {
    background-color: white;
    margin: 15% auto;
    padding: 30px;
    border-radius: 8px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.delete-modal-content h3 {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: 600;
    color: #333;
    margin: 0 0 15px 0;
}

.delete-modal-content p {
    font-family: 'Sentinel', serif;
    font-size: 16px;
    color: #666;
    margin: 0 0 25px 0;
    line-height: 1.5;
}

.delete-modal-actions {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
}

.delete-modal-btn {
    background: #dc3545;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
    min-width: 120px;
}

.delete-modal-btn:hover {
    background: #c82333;
}

.delete-modal-btn.cancel-btn {
    background: #6c757d;
}

.delete-modal-btn.cancel-btn:hover {
    background: #5a6268;
}

/* PDF Modal Styles */
.pdf-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.pdf-modal-content {
    background: white;
    margin: 5% auto;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
}

.pdf-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    padding-bottom: 15px;
    border-bottom: 2px solid #AF232D;
}

.pdf-modal-title {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: 500;
    color: #AF232D;
    margin: 0;
}

.pdf-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: #666;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: background-color 0.2s ease;
}

.pdf-modal-close:hover {
    background: #f0f0f0;
    color: #AF232D;
}

.pdf-form-group {
    margin-bottom: 25px;
}

.pdf-form-group label {
    display: block;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 10px;
}

.pdf-date-range {
    display: flex;
    gap: 15px;
}

.pdf-date-range > div {
    flex: 1;
}

.pdf-date-range label {
    font-size: 13px;
    margin-bottom: 5px;
}

.pdf-date-range input {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 6px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    transition: border-color 0.2s ease;
}

.pdf-date-range input:focus {
    outline: none;
    border-color: #AF232D;
    box-shadow: 0 0 0 2px rgba(175, 35, 45, 0.1);
}

.pdf-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 8px;
    margin-top: 10px;
}

.pdf-category-option {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px;
    border: 1px solid #eee;
    border-radius: 6px;
    transition: background-color 0.2s ease;
}

.pdf-category-option:hover {
    background: #f8f9fa;
}

.pdf-category-option input[type="checkbox"] {
    margin: 0;
    width: auto;
}

.pdf-category-option label {
    margin: 0;
    font-size: 13px;
    font-weight: normal;
    cursor: pointer;
}

.pdf-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #eee;
}

.pdf-cancel-btn {
    background: #f8f9fa;
    color: #666;
    border: 1px solid #dee2e6;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s ease;
}

.pdf-cancel-btn:hover {
    background: #e9ecef;
    border-color: #adb5bd;
}

.pdf-generate-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.pdf-generate-btn:hover {
    background: #8B1C24;
}

.pdf-generate-btn:disabled {
    background: #ccc;
    cursor: not-allowed;
}

/* Chapter Roster Modal Styles */
.roster-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.roster-modal-content {
    background: white;
    margin: 2% auto;
    padding: 0;
    border-radius: 12px;
    width: 95%;
    max-width: 1200px;
    max-height: 90vh;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    animation: modalSlideIn 0.3s ease-out;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.roster-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px 20px 30px;
    border-bottom: 2px solid #AF232D;
    background: white;
    flex-shrink: 0;
}

.roster-modal-title {
    font-family: 'Sentinel', serif;
    font-size: 24px;
    font-weight: 600;
    color: #AF232D;
    margin: 0;
}

.roster-modal-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.roster-edit-btn {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.roster-edit-btn:hover {
    background: #8B1C24;
}

.roster-edit-btn.save-mode {
    background: #28a745;
}

.roster-edit-btn.save-mode:hover {
    background: #218838;
}

.roster-export-dropdown {
    position: relative;
}

.roster-export-btn {
    background: #6c757d;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 8px 16px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
}

.roster-export-btn:hover {
    background: #5a6268;
}

.roster-export-menu {
    display: none;
    position: absolute;
    top: 100%;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-radius: 6px;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
    z-index: 1001;
    min-width: 100px;
}

.roster-export-menu.show {
    display: block;
}

.roster-export-option {
    display: block;
    width: 100%;
    padding: 8px 16px;
    background: none;
    border: none;
    text-align: left;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.roster-export-option:hover {
    background: #f8f9fa;
}

.roster-export-option:first-child {
    border-radius: 6px 6px 0 0;
}

.roster-export-option:last-child {
    border-radius: 0 0 6px 6px;
}

.roster-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.roster-modal-close:hover {
    background: #f8f9fa;
    color: #AF232D;
}

.roster-filters {
    padding: 20px 30px;
    border-bottom: 1px solid #eee;
    background: #f8f9fa;
    display: flex;
    flex-wrap: wrap;
    gap: 15px;
    flex-shrink: 0;
}

.roster-filter-option {
    display: flex;
    align-items: center;
    gap: 8px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    user-select: none;
}

.roster-filter-option input[type="checkbox"] {
    margin: 0;
    transform: scale(1.2);
    accent-color: #AF232D;
}

.roster-filter-option span {
    color: #333;
}

.roster-table-container {
    flex: 1;
    overflow: auto;
    padding: 0;
}

.roster-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'Sentinel', serif;
    background: white;
}

.roster-table th {
    background: #f8f9fa;
    padding: 15px 12px;
    text-align: left;
    font-weight: 600;
    color: #333;
    border-bottom: 2px solid #dee2e6;
    position: sticky;
    top: 0;
    z-index: 10;
}

.roster-table td {
    padding: 12px;
    border-bottom: 1px solid #dee2e6;
    vertical-align: top;
    line-height: 1.4;
}

.roster-table tbody tr:hover {
    background: #f8f9fa;
}

.roster-table .address-cell {
    max-width: 200px;
    white-space: pre-line;
    word-wrap: break-word;
}

.roster-table .email-cell {
    max-width: 180px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.roster-table .phone-cell {
    white-space: nowrap;
}

.roster-table .dc-approval-cell {
    text-align: center;
    font-weight: 500;
}

/* Edit mode styles for roster table */
.roster-table.edit-mode td {
    padding: 8px;
}

.roster-table.edit-mode .editable-cell input {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    background: white;
}

.roster-table.edit-mode .editable-cell textarea {
    width: 100%;
    padding: 6px 8px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    background: white;
    resize: vertical;
    min-height: 60px;
}

.roster-table.edit-mode .non-editable {
    background: #f8f9fa;
    color: #666;
    font-style: italic;
}

.roster-error-message {
    background: #f8d7da;
    color: #721c24;
    padding: 10px 15px;
    margin: 10px 30px;
    border-radius: 4px;
    border: 1px solid #f5c6cb;
}

.roster-success-message {
    background: #d4edda;
    color: #155724;
    padding: 10px 15px;
    margin: 10px 30px;
    border-radius: 4px;
    border: 1px solid #c3e6cb;
}

/* Roster delete button styles */
.roster-delete-btn {
    background: none;
    border: none;
    font-size: 16px;
    cursor: pointer;
    padding: 4px 8px;
    border-radius: 4px;
    transition: all 0.3s ease;
    opacity: 0.6;
}

.roster-delete-btn:hover {
    background: rgba(220, 53, 69, 0.1);
    opacity: 1;
    transform: scale(1.1);
}

.actions-cell {
    text-align: center;
    width: 60px;
}

/* Responsive Design */
@media (max-width: 1024px) {
    .dashboard-container {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .calendar-actions {
        flex-direction: column;
        gap: 4px;
    }
}

@media (max-width: 768px) {
    .dashboard-main {
        padding: 10px;
    }
    
    .recipient-groups {
        flex-direction: column;
    }
    
    .recipient-group-btn {
        text-align: center;
    }
    
    .event-modal-content {
        width: 95%;
        margin: 10% auto;
    }
    
    .event-form-grid {
        grid-template-columns: 1fr;
        gap: 15px;
    }
    
    .event-modal-actions {
        flex-direction: column;
        gap: 15px;
        align-items: stretch;
    }
    
    .event-modal-actions-right {
        justify-content: stretch;
    }
    
    .calendar-day {
        min-height: 80px;
    }
    
    .calendar-event {
        font-size: 9px;
    }
}

/* Modal Styles */
.invite-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0,0,0,0.5);
}

.invite-modal-content {
    background-color: white;
    margin: 2% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 800px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.invite-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 20px 0 20px;
    border-bottom: 2px solid #AF232D;
    margin-bottom: 20px;
}

.invite-modal-header h3 {
    font-family: 'Sentinel', serif;
    font-size: 24px;
    color: #AF232D;
    margin: 0 0 8px 0;
    font-weight: bold;
}

.close-modal-btn {
    background: none;
    border: none;
    font-size: 28px;
    color: #AF232D;
    cursor: pointer;
    padding: 0;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.close-modal-btn:hover {
    color: #8f1d25;
}

.invite-modal-content .guidance-text {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    color: #333;
    line-height: 1.5;
    padding: 0 20px;
}

.invite-modal-content form {
    padding: 0 20px 20px 20px;
}

/* Confrère Invitation Styles in Modal */
.invite-modal .confrere-invitation-box {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.invite-modal .confrere-invitation-title {
    font-family: 'Sentinel', serif;
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin: 0 0 20px 0;
    border-bottom: 2px solid #AF232D;
    padding-bottom: 8px;
}

.invite-modal .confrere-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.invite-modal .confrere-form-group {
    display: flex;
    flex-direction: column;
}

.invite-modal .confrere-form-group label {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 5px;
}

.invite-modal .confrere-form-group input {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    background: white;
    width: 100%;
    box-sizing: border-box;
}

.invite-modal .confrere-form-group input:focus {
    outline: none;
    border-color: #AF232D;
}

.invite-modal .confrere-form-full-width {
    grid-column: 1 / -1;
}

.invite-modal .confrere-invite-button {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    margin-bottom: 10px;
}

.invite-modal .confrere-invite-button:hover {
    background: #8f1d25;
}

.invite-modal .confrere-message {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    margin-bottom: 20px;
    padding: 8px 12px;
    border-radius: 4px;
    display: none;
}

.invite-modal .confrere-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.invite-modal .confrere-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.invite-modal .confrere-table-wrapper {
    margin-top: 20px;
    overflow-x: auto;
    padding: 0 20px 20px 20px;
}

.invite-modal .confrere-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'Sentinel', serif;
}

.invite-modal .confrere-table th,
.invite-modal .confrere-table td {
    padding: 12px;
    text-align: left;
    border-bottom: 1px solid #ddd;
}

.invite-modal .confrere-table th {
    background-color: #f8f9fa;
    font-weight: 500;
    color: #333;
}

/* Officer Invitation Styles in Modal */
.invite-modal .officer-invitation-box {
    background: white;
    border-radius: 8px;
    padding: 20px;
    margin-top: 20px;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.invite-modal .officer-invitation-title {
    font-family: 'Sentinel', serif;
    font-size: 18px;
    font-weight: 500;
    color: #333;
    margin: 0 0 20px 0;
    border-bottom: 2px solid #AF232D;
    padding-bottom: 8px;
}

.invite-modal .officer-form-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 15px;
    margin-bottom: 20px;
}

.invite-modal .officer-form-group {
    display: flex;
    flex-direction: column;
}

.invite-modal .officer-form-group label {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    color: #333;
    margin-bottom: 5px;
}

.invite-modal .officer-form-group input,
.invite-modal .officer-form-group select {
    padding: 8px 12px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    background: white;
    width: 100%;
    box-sizing: border-box;
}

.invite-modal .officer-form-group input:focus,
.invite-modal .officer-form-group select:focus {
    outline: none;
    border-color: #AF232D;
}

.invite-modal .officer-invite-button {
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 10px 20px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    margin-bottom: 10px;
}

.invite-modal .officer-invite-button:hover {
    background: #8f1d25;
}

.invite-modal .officer-message {
    font-family: 'Sentinel', serif;
    font-size: 14px;
    margin-bottom: 20px;
    padding: 8px 12px;
    border-radius: 4px;
    display: none;
}

.invite-modal .officer-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.invite-modal .officer-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.invite-modal .officer-table-wrapper {
    margin-top: 20px;
    overflow-x: auto;
    padding: 0 20px 20px 20px;
}

.invite-modal .officer-table {
    width: 100%;
    border-collapse: collapse;
    font-family: 'Sentinel', serif;
    font-size: 14px;
}

.invite-modal .officer-table th {
    background: #f8f9fa;
    padding: 12px 8px;
    text-align: left;
    font-weight: 500;
    border-bottom: 2px solid #AF232D;
    color: #333;
}

.invite-modal .officer-table td {
    padding: 12px 8px;
    border-bottom: 1px solid #eee;
    color: #333;
}

.invite-modal .officer-table tbody tr:hover {
    background: #f8f9fa;
}

.invite-modal .officer-dropdown-container {
    position: relative;
}

.invite-modal .officer-dropdown {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: white;
    border: 1px solid #ddd;
    border-top: none;
    border-radius: 0 0 4px 4px;
    max-height: 200px;
    overflow-y: auto;
    z-index: 1000;
    display: none;
}

.invite-modal .officer-dropdown-item {
    padding: 8px 12px;
    cursor: pointer;
    font-family: 'Sentinel', serif;
    font-size: 14px;
}

.invite-modal .officer-dropdown-item:hover {
    background: #f8f9fa;
}

.invite-modal .officer-dropdown-name {
    font-weight: 500;
    color: #333;
}

.invite-modal .officer-dropdown-email {
    font-size: 12px;
    color: #666;
    margin-top: 2px;
}

/* Officer Edit/Delete Styles for Modal */
.invite-modal .officer-edit-pencil {
    width: 16px;
    height: 16px;
    fill: #ddd;
    cursor: pointer;
    transition: fill 0.2s;
    margin: 0 2px;
}

.invite-modal .officer-table tr:hover .officer-edit-pencil {
    fill: #888;
}

.invite-modal .officer-delete-trash {
    width: 16px;
    height: 16px;
    fill: #ddd;
    cursor: pointer;
    transition: fill 0.2s;
    margin: 0 2px;
}

.invite-modal .officer-table tr:hover .officer-delete-trash {
    fill: #dc3545;
}

.invite-modal .officer-delete-trash:hover {
    fill: #c82333 !important;
}

.invite-modal .officer-actions {
    display: flex;
    justify-content: center;
    align-items: center;
}

.invite-modal .officer-editing-row {
    background: #f5eaea !important;
}

.invite-modal .officer-save-btn {
    background: #28a745;
    color: white;
    border: none;
    border-radius: 4px;
    padding: 5px 10px;
    font-size: 12px;
    cursor: pointer;
    margin-bottom: 5px;
}

.invite-modal .officer-save-btn:hover {
    background: #218838;
}

.invite-modal .officer-edit-error {
    color: #dc3545;
    font-size: 11px;
    margin-top: 2px;
}

/* Delete Modal Styles */
.officer-delete-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: none;
    justify-content: center;
    align-items: center;
    z-index: 1001;
}

.officer-delete-modal.show {
    display: flex;
}

.officer-delete-dialog {
    background: white;
    border-radius: 8px;
    padding: 24px;
    max-width: 400px;
    width: 90%;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
}

.officer-delete-title {
    font-family: 'Sentinel', serif;
    font-size: 20px;
    font-weight: bold;
    color: #AF232D;
    margin-bottom: 16px;
    text-align: center;
}

.officer-delete-message {
    font-family: 'Sentinel', serif;
    font-size: 16px;
    color: #333;
    margin-bottom: 20px;
    text-align: center;
    line-height: 1.4;
}

.officer-delete-buttons {
    display: flex;
    gap: 12px;
    justify-content: center;
}

.officer-delete-btn, .officer-cancel-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.officer-delete-btn {
    background: #dc3545;
    color: white;
}

.officer-delete-btn:hover {
    background: #c82333;
}

.officer-cancel-btn {
    background: #6c757d;
    color: white;
}

.officer-cancel-btn:hover {
    background: #545b62;
}

/* Ongoing Rhythm Modal Styles */
.ongoing-rhythm-modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(4px);
}

.ongoing-rhythm-modal-content {
    position: relative;
    background-color: white;
    margin: 2% auto;
    padding: 0;
    border-radius: 12px;
    width: 90%;
    max-width: 900px;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.3);
    display: flex;
    flex-direction: column;
    animation: modalSlideIn 0.3s ease-out;
}

.ongoing-rhythm-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 25px 30px 20px 30px;
    border-bottom: 2px solid #AF232D;
    background: white;
    flex-shrink: 0;
}

.ongoing-rhythm-modal-title {
    font-family: 'Sentinel', serif;
    font-size: 24px;
    font-weight: 600;
    color: #AF232D;
    margin: 0;
}

.ongoing-rhythm-modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: #999;
    cursor: pointer;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    transition: all 0.3s ease;
}

.ongoing-rhythm-modal-close:hover {
    background: #f8f9fa;
    color: #AF232D;
}

.ongoing-rhythm-content {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}

.ongoing-rhythm-section {
    margin-bottom: 40px;
    padding-bottom: 30px;
    border-bottom: 1px solid #eee;
}

.ongoing-rhythm-section:last-child {
    border-bottom: none;
    margin-bottom: 0;
}

.ongoing-rhythm-step-header {
    display: flex;
    align-items: center;
    margin-bottom: 20px;
}

.ongoing-rhythm-step-number {
    background: #AF232D;
    color: white;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-family: 'Sentinel', serif;
    font-weight: 600;
    font-size: 16px;
    margin-right: 15px;
    flex-shrink: 0;
}

.ongoing-rhythm-step-title {
    font-family: 'Sentinel', serif;
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin: 0;
}

.ongoing-rhythm-step-content {
    margin-left: 47px;
}

.ongoing-rhythm-section-header {
    font-family: 'Sentinel', serif;
    font-size: 18px;
    font-weight: 600;
    color: #AF232D;
    margin: 0 0 15px 0;
}

.ongoing-rhythm-guidance-text {
    font-family: 'Sentinel', serif;
    font-size: 16px;
    line-height: 1.6;
    color: #333;
    margin: 0 0 12px 0;
}

.ongoing-rhythm-guidance-text a {
    color: #AF232D;
    text-decoration: underline;
    transition: color 0.3s ease;
}

.ongoing-rhythm-guidance-text a:hover {
    color: #8B1C24;
}

.ongoing-rhythm-guidance-text strong {
    font-weight: 600;
}

/* Mobile responsiveness for ongoing rhythm modal */
@media (max-width: 768px) {
    .ongoing-rhythm-modal-content {
        margin: 5% auto;
        width: 95%;
        max-height: 90vh;
    }
    
    .ongoing-rhythm-modal-header {
        padding: 20px;
    }
    
    .ongoing-rhythm-modal-title {
        font-size: 20px;
    }
    
    .ongoing-rhythm-content {
        padding: 20px;
    }
    
    .ongoing-rhythm-step-title {
        font-size: 20px;
    }
    
    .ongoing-rhythm-step-content {
        margin-left: 0;
        margin-top: 15px;
    }
    
    .ongoing-rhythm-step-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 10px;
    }
    
    .ongoing-rhythm-step-number {
        margin-right: 0;
    }
}

@media (max-width: 768px) {
    .invite-modal-content {
        width: 95%;
        margin: 5% auto;
        max-height: 85vh;
    }

    .invite-modal .confrere-form-grid,
    .invite-modal .officer-form-grid {
        grid-template-columns: 1fr;
    }
} 
/* Template Modal Styles (BETA) */
.template-modal {
    display: none;
    position: fixed;
    z-index: 1001;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.5);
    overflow-y: auto;
}

.template-modal-content {
    background-color: #ffffff;
    margin: 3% auto;
    padding: 0;
    border-radius: 8px;
    width: 90%;
    max-width: 600px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    max-height: 90vh;
    overflow-y: auto;
}

.template-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 25px;
    border-bottom: 2px solid #AF232D;
    position: sticky;
    top: 0;
    background: white;
    z-index: 10;
}

.template-modal-header h3 {
    margin: 0;
    font-family: 'Sentinel', serif;
    font-size: 22px;
    color: #AF232D;
}

.template-form {
    padding: 25px;
}

.template-section {
    margin-bottom: 20px;
}

.template-section label {
    display: block;
    margin-bottom: 8px;
    font-family: 'Sentinel', serif;
    font-weight: 500;
    color: #333;
    font-size: 15px;
}

.template-section input[type="text"],
.template-section input[type="date"],
.template-section input[type="time"],
.template-section textarea {
    width: 100%;
    padding: 10px;
    border: 1px solid #ddd;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    box-sizing: border-box;
}

.template-section textarea {
    resize: vertical;
    min-height: 80px;
}

.template-checkbox-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px;
    background: #f8f9fa;
    border-radius: 4px;
    max-height: 200px;
    overflow-y: auto;
}

.template-checkbox-label {
    display: flex;
    align-items: center;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    color: #333;
    cursor: pointer;
    padding: 5px;
    border-radius: 3px;
    transition: background-color 0.2s;
}

.template-checkbox-label:hover {
    background-color: #e9ecef;
}

.template-checkbox-label input[type="checkbox"] {
    margin-right: 10px;
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.template-modal-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding-top: 20px;
    border-top: 1px solid #e0e0e0;
    margin-top: 20px;
}

.template-create-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 4px;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    color: white;
}

.template-create-btn:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

/* Mobile Responsiveness for Template Modal */
@media (max-width: 768px) {
    .template-modal-content {
        width: 95%;
        margin: 5% auto;
        max-height: 92vh;
    }

    .template-modal-header {
        padding: 15px 20px;
    }

    .template-modal-header h3 {
        font-size: 18px;
    }

    .template-form {
        padding: 20px;
    }

    .template-section {
        margin-bottom: 15px;
    }

    .template-checkbox-list {
        max-height: 150px;
    }

    .template-modal-actions {
        flex-direction: column-reverse;
    }

    .template-modal-actions button {
        width: 100%;
    }

    .template-create-btn {
        font-size: 13px;
        padding: 8px 15px;
    }
}

@media (max-width: 480px) {
    .template-modal-header h3 {
        font-size: 16px;
    }

    .template-form {
        padding: 15px;
    }

    .template-section label {
        font-size: 14px;
    }

    .template-checkbox-list {
        max-height: 120px;
    }
}

/* Document Viewer Modal */
.document-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.document-modal-content {
    background: white;
    border-radius: 8px;
    width: 100%;
    max-width: 900px;
    max-height: 90vh;
    display: flex;
    flex-direction: column;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.3);
}

.document-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    border-bottom: 2px solid #AF232D;
}

.document-modal-header h2 {
    margin: 0;
    color: #AF232D;
    font-family: 'Sentinel', serif;
    font-size: 22px;
    flex: 1;
}

.document-modal-actions {
    display: flex;
    gap: 15px;
    align-items: center;
}

.document-action-btn {
    padding: 10px 20px;
    background: #AF232D;
    color: white;
    border: none;
    border-radius: 5px;
    cursor: pointer;
    font-family: 'Sentinel', serif;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 8px;
    transition: background 0.2s;
}

.document-action-btn:hover {
    background: #8B1A24;
}

.document-close-btn {
    background: none;
    border: none;
    font-size: 28px;
    cursor: pointer;
    color: #666;
    padding: 0;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 4px;
    transition: background 0.2s;
}

.document-close-btn:hover {
    background: #f0f0f0;
    color: #333;
}

.document-modal-body {
    flex: 1;
    overflow-y: auto;
    padding: 30px;
}

.document-loading {
    text-align: center;
    padding: 60px 20px;
    color: #666;
    font-size: 18px;
}

.document-content {
    font-family: 'Sentinel', Georgia, serif;
    line-height: 1.6;
    color: #333;
}

.document-content h1 {
    color: #AF232D;
    border-bottom: 3px solid #AF232D;
    padding-bottom: 10px;
    margin-bottom: 30px;
}

.document-content h2 {
    color: #AF232D;
    margin-top: 30px;
    margin-bottom: 15px;
}

@media print {
    .document-modal-header {
        display: none !important;
    }
    
    .document-modal-body {
        padding: 0;
    }
}
