/*
 * Catholic Prayer Journal Styles
 * 
 * Scoped styles that only affect the prayer journal interface.
 * Uses the specified color palette for a cohesive Catholic theme.
 * 
 * @package CatholicPrayerJournal
 * @version 1.0.0
 */

/* ========================================
   CSS RESET & SCOPING
======================================== */

/* Scope all styles to the prayer journal container */
#cpj-prayer-journal,
#cpj-prayer-journal * {
    box-sizing: border-box;
}

#cpj-prayer-journal {
    font-family: 'Georgia', 'Times New Roman', serif;
    line-height: 1.6;
    color: #333;
    background: linear-gradient(135deg, #F5F5F5 0%, #f4e1e6 100%);
    border-radius: 15px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    position: relative;
    margin: 20px 0;
    min-height: 600px;
}

/* ========================================
   COLOR VARIABLES
======================================== */

:root {
    --cpj-primary: #f7a1b2;        /* rgb(247, 161, 178) */
    --cpj-secondary: #f6c6d7;      /* rgb(246, 198, 215) */
    --cpj-light: #f4e1e6;          /* rgb(244, 225, 230) */
    --cpj-accent: #e3c8e4;         /* rgb(227, 200, 228) */
    --cpj-dark: #d2a8d6;           /* rgb(210, 168, 214) */
    --cpj-background: #F5F5F5;     /* rgb(245, 245, 245) */
    --cpj-text: #333;
    --cpj-text-light: #666;
    --cpj-text-muted: #888;
    --cpj-border: #ddd;
    --cpj-success: #28a745;
    --cpj-warning: #ffc107;
    --cpj-danger: #dc3545;
    --cpj-info: #17a2b8;
}

/* ========================================
   LOADING OVERLAY
======================================== */

.cpj-loading-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.95);
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 1;
    transition: opacity 0.3s ease;
}

.cpj-loading-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.cpj-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--cpj-light);
    border-top: 4px solid var(--cpj-primary);
    border-radius: 50%;
    animation: cpj-spin 1s linear infinite;
    margin-bottom: 15px;
}

.cpj-spinner-small {
    width: 20px;
    height: 20px;
    border: 2px solid var(--cpj-light);
    border-top: 2px solid var(--cpj-primary);
    border-radius: 50%;
    animation: cpj-spin 1s linear infinite;
    display: inline-block;
    margin-right: 10px;
}

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

/* ========================================
   HEADER SECTION
======================================== */

.cpj-header {
    background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
    padding: 25px 30px;
    color: white;
    position: relative;
    overflow: hidden;
}

.cpj-header::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: url('data:image/svg+xml,<svg xmlns="http://www.w3.org/2000/svg" viewBox="0 0 100 100"><circle cx="20" cy="20" r="2" fill="rgba(255,255,255,0.1)"/><circle cx="80" cy="80" r="1.5" fill="rgba(255,255,255,0.08)"/><circle cx="60" cy="30" r="1" fill="rgba(255,255,255,0.06)"/></svg>');
    animation: cpj-float 20s ease-in-out infinite;
    pointer-events: none;
}

@keyframes cpj-float {
    0%, 100% { transform: translate(0, 0) rotate(0deg); }
    50% { transform: translate(-10px, -10px) rotate(180deg); }
}

.cpj-scripture-container {
    position: relative;
    z-index: 2;
    margin-bottom: 20px;
}

.cpj-scripture-quote {
    background: rgba(255, 255, 255, 0.15);
    border-left: 4px solid rgba(255, 255, 255, 0.3);
    padding: 20px;
    border-radius: 8px;
    margin: 0;
    backdrop-filter: blur(10px);
}

.cpj-quote-text {
    font-size: 18px;
    font-style: italic;
    margin: 0 0 10px 0;
    line-height: 1.5;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.cpj-quote-reference {
    font-size: 14px;
    opacity: 0.9;
    font-weight: 600;
    text-align: right;
    margin: 0;
}

.cpj-user-status {
    display: flex;
    justify-content: flex-end;
    align-items: center;
    position: relative;
    z-index: 100;
    padding: 10px 0;
}

/* Logged-in User Profile */
.cpj-user-profile {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(10px);
    border-radius: 25px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
}

.cpj-user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--cpj-primary), var(--cpj-secondary));
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    color: white;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.15);
}

.cpj-user-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cpj-welcome-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 400;
}

.cpj-user-name {
    font-size: 14px;
    color: white;
    font-weight: 600;
}

.cpj-user-menu {
    position: relative;
}

.cpj-user-menu-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: rgba(255, 255, 255, 0.1);
    color: white;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
}

.cpj-user-menu-btn:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: scale(1.05);
}

.cpj-menu-dots {
    font-size: 16px;
    font-weight: bold;
}

.cpj-user-dropdown {
    position: absolute;
    top: 100%;
    right: 0;
    margin-top: 8px;
    background: white;
    border-radius: 12px;
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
    border: 1px solid #e1e5e9;
    min-width: 200px;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 1000;
}

.cpj-user-menu:hover .cpj-user-dropdown,
.cpj-user-dropdown:hover,
.cpj-user-dropdown.cpj-show {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Prayer Request Styling */
.cpj-prayer-card {
    background: rgba(255, 255, 255, 0.95);
    border: 1px solid rgba(227, 200, 228, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
}

.cpj-prayer-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 16px rgba(0, 0, 0, 0.15);
}

.cpj-prayer-card.cpj-answered {
    border-left: 4px solid #28a745;
    background: rgba(40, 167, 69, 0.05);
}

.cpj-prayer-card.cpj-starred {
    border-left: 4px solid #ffc107;
    background: rgba(255, 193, 7, 0.05);
}

.cpj-request-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 12px;
    flex-wrap: wrap;
    gap: 10px;
}

.cpj-request-meta {
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
}

.cpj-request-meta .cpj-date {
    color: #666;
    font-size: 0.9em;
    font-weight: 500;
}

.cpj-answered-badge {
    background: #28a745;
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 0.8em;
    font-weight: 600;
}

.cpj-request-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.cpj-request-action {
    background: rgba(247, 161, 178, 0.1);
    border: 1px solid rgba(247, 161, 178, 0.3);
    border-radius: 8px;
    padding: 6px 10px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
    color: #333;
    min-width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cpj-request-action:hover {
    background: rgba(247, 161, 178, 0.2);
    border-color: rgba(247, 161, 178, 0.5);
    transform: translateY(-1px);
}

.cpj-request-action:active {
    transform: translateY(0);
}

.cpj-request-content {
    color: #333;
    line-height: 1.6;
    font-size: 15px;
    margin-top: 12px;
    padding: 12px;
    background: rgba(244, 225, 230, 0.3);
    border-radius: 8px;
    border-left: 3px solid rgba(247, 161, 178, 0.5);
    transition: all 0.3s ease;
}

.cpj-request-content.cpj-editing {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(247, 161, 178, 0.8);
    border-left: 3px solid rgba(247, 161, 178, 1);
    outline: none;
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
}

.cpj-request-content.cpj-editing:focus {
    border-color: rgba(247, 161, 178, 1);
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.2);
}

/* Journal Entry Inline Editing */
.cpj-entry-content.cpj-editing,
.cpj-entry-title.cpj-editing {
    background: rgba(255, 255, 255, 0.9);
    border: 2px solid rgba(247, 161, 178, 0.8);
    border-radius: 8px;
    outline: none;
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
    transition: all 0.3s ease;
    padding: 12px;
}

.cpj-entry-content.cpj-editing:focus,
.cpj-entry-title.cpj-editing:focus {
    border-color: rgba(247, 161, 178, 1);
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.2);
}

.cpj-entry-title.cpj-editing {
    padding: 8px 12px;
    margin-bottom: 8px;
}

.cpj-prayer-updates {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid rgba(227, 200, 228, 0.3);
}

.cpj-prayer-updates h4 {
    color: #666;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cpj-prayer-update {
    background: rgba(210, 168, 214, 0.1);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 8px;
    border-left: 3px solid rgba(210, 168, 214, 0.5);
}

.cpj-update-meta {
    color: #666;
    font-size: 0.85em;
    margin-bottom: 6px;
    font-weight: 500;
}

.cpj-update-text {
    color: #333;
    line-height: 1.5;
}

.cpj-no-entries {
    text-align: center;
    color: #666;
    font-style: italic;
    padding: 40px 20px;
    background: rgba(244, 225, 230, 0.3);
    border-radius: 12px;
    border: 2px dashed rgba(227, 200, 228, 0.5);
}

/* Prayer tracking specific styles */
.cpj-prayer-status-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid rgba(227, 200, 228, 0.3);
}

.cpj-status-badge {
    display: inline-block;
    padding: 4px 10px;
    border-radius: 15px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.cpj-status-badge.cpj-status-started,
.cpj-status-badge.cpj-status-ongoing {
    background: rgba(247, 161, 178, 0.2);
    color: #d63384;
    border: 1px solid rgba(247, 161, 178, 0.5);
}

.cpj-status-badge.cpj-status-completed {
    background: rgba(40, 167, 69, 0.2);
    color: #28a745;
    border: 1px solid rgba(40, 167, 69, 0.5);
}

.cpj-status-badge.cpj-status-paused {
    background: rgba(255, 193, 7, 0.2);
    color: #ffc107;
    border: 1px solid rgba(255, 193, 7, 0.5);
}

.cpj-status-badge.cpj-status-incomplete {
    background: rgba(220, 53, 69, 0.2);
    color: #dc3545;
    border: 1px solid rgba(220, 53, 69, 0.5);
}

.cpj-status-badge.cpj-status-cancelled {
    background: rgba(108, 117, 125, 0.2);
    color: #6c757d;
    border: 1px solid rgba(108, 117, 125, 0.5);
}

.cpj-prayer-type {
    background: rgba(227, 200, 228, 0.3);
    padding: 3px 8px;
    border-radius: 10px;
    font-size: 11px;
    color: #8e44ad;
    margin-right: 10px;
}

.cpj-prayer-dates {
    margin-top: 12px;
    padding: 10px;
    background: rgba(245, 245, 245, 0.7);
    border-radius: 8px;
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 10px;
}

.cpj-prayer-dates .cpj-date-info {
    flex: 1;
    min-width: 120px;
}

.cpj-prayer-dates small {
    color: #666;
    font-size: 12px;
}

.cpj-prayer-notes {
    margin-top: 12px;
    padding: 10px;
    background: rgba(246, 198, 215, 0.1);
    border-radius: 8px;
    border-left: 3px solid var(--cpj-secondary);
}

.cpj-prayer-notes p {
    margin: 0;
    font-size: 14px;
    color: #555;
}

.cpj-btn-sm {
    font-size: 12px;
    padding: 6px 12px;
    border-radius: 15px;
}

.cpj-prayer-section {
    margin-bottom: 25px;
}

.cpj-section-title {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 15px;
    padding: 10px 15px;
    background: linear-gradient(135deg, rgba(247, 161, 178, 0.1), rgba(246, 198, 215, 0.1));
    border-radius: 10px;
    font-size: 18px;
    font-weight: 600;
    color: #333;
}

.cpj-section-title .cpj-count {
    background: var(--cpj-primary);
    color: white;
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    margin-left: auto;
}

/* Tab Info Box Styles */
.cpj-header-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 10px;
}

.cpj-info-toggle {
    background: rgba(247, 161, 178, 0.2);
    border: 1px solid rgba(247, 161, 178, 0.4);
    border-radius: 50%;
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 16px;
}

.cpj-info-toggle:hover {
    background: rgba(247, 161, 178, 0.3);
    transform: scale(1.1);
}

.cpj-info-box {
    background: linear-gradient(135deg, rgba(227, 200, 228, 0.1), rgba(244, 225, 230, 0.1));
    border: 1px solid rgba(227, 200, 228, 0.3);
    border-radius: 12px;
    padding: 20px;
    margin-top: 15px;
    animation: slideDown 0.3s ease-out;
}

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

.cpj-info-content h4 {
    margin: 0 0 15px 0;
    color: #8e44ad;
    font-size: 16px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.cpj-info-content h4::before {
    content: "💡";
    font-size: 18px;
}

.cpj-info-content p {
    margin: 8px 0;
    line-height: 1.5;
    font-size: 14px;
    color: #555;
}

.cpj-info-content p strong {
    color: #8e44ad;
    font-weight: 600;
}

.cpj-info-content p:last-child {
    margin-bottom: 0;
}

/* Search Box Styles */
.cpj-search-section {
    margin: 20px 0;
    padding: 0 5px;
}

.cpj-search-box {
    position: relative;
    max-width: 400px;
    margin: 0 auto;
}

.cpj-search-input {
    width: 100%;
    padding: 12px 40px 12px 16px;
    border: 2px solid rgba(227, 200, 228, 0.4);
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.9);
    font-size: 14px;
    color: #333;
    transition: all 0.3s ease;
    outline: none;
}

.cpj-search-input:focus {
    border-color: var(--cpj-primary);
    background: rgba(255, 255, 255, 1);
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
}

.cpj-search-input::placeholder {
    color: #999;
    font-style: italic;
}

.cpj-search-clear {
    position: absolute;
    right: 8px;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(227, 200, 228, 0.3);
    border: none;
    border-radius: 50%;
    width: 28px;
    height: 28px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    opacity: 0;
    pointer-events: none;
}

.cpj-search-clear.active {
    opacity: 1;
    pointer-events: all;
}

.cpj-search-clear:hover {
    background: rgba(227, 200, 228, 0.5);
    transform: translateY(-50%) scale(1.1);
}

.cpj-search-clear i {
    font-size: 12px;
    color: #666;
}

/* Search result highlighting */
.cpj-search-highlight {
    background: rgba(247, 161, 178, 0.3);
    padding: 1px 2px;
    border-radius: 3px;
    font-weight: 500;
}

/* Mobile responsiveness for prayer cards */
@media (max-width: 768px) {
    .cpj-prayer-card {
        padding: 16px;
        margin-bottom: 12px;
    }
    
    .cpj-request-header {
        flex-direction: column;
        align-items: stretch;
    }
    
    .cpj-request-actions {
        justify-content: flex-end;
        margin-top: 8px;
    }
    
    .cpj-request-action {
        padding: 8px 12px;
        font-size: 16px;
    }
    
    .cpj-request-content {
        font-size: 14px;
        padding: 10px;
    }
}

.cpj-dropdown-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    color: #374151;
    text-decoration: none;
    border: none;
    background: none;
    width: 100%;
    text-align: left;
    cursor: pointer;
    transition: background-color 0.2s ease;
    font-size: 14px;
}

.cpj-dropdown-item:hover {
    background: #f8f9fa;
}

.cpj-dropdown-item:first-child {
    border-radius: 12px 12px 0 0;
}

.cpj-dropdown-item:last-child {
    border-radius: 0 0 12px 12px;
}

.cpj-item-icon {
    font-size: 16px;
}

.cpj-dropdown-divider {
    margin: 8px 0;
    border: none;
    border-top: 1px solid #e5e7eb;
}

/* Guest Status */
.cpj-guest-status {
    display: flex;
    align-items: center;
    gap: 12px;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 25px;
    padding: 8px 16px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.cpj-guest-avatar {
    width: 36px;
    height: 36px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    color: rgba(255, 255, 255, 0.8);
}

.cpj-guest-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.cpj-guest-text {
    font-size: 12px;
    color: rgba(255, 255, 255, 0.8);
    font-weight: 400;
}

.cpj-guest-notice {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.9);
}

.cpj-login-link {
    color: white;
    text-decoration: underline;
    font-weight: 600;
}

.cpj-login-link:hover {
    color: var(--cpj-light);
}

/* ========================================
   MAIN CONTENT AREA
======================================== */

.cpj-main-content {
    display: flex;
    flex-direction: column;
    height: calc(100% - 160px);
    min-height: 500px;
}

/* ========================================
   TAB NAVIGATION
======================================== */

.cpj-tab-navigation {
    display: flex;
    background: white;
    border-bottom: 2px solid var(--cpj-light);
    overflow-x: auto;
    scrollbar-width: none; /* Firefox */
    -ms-overflow-style: none; /* IE and Edge */
}

.cpj-tab-navigation::-webkit-scrollbar {
    display: none; /* Chrome, Safari */
}

.cpj-tab-btn {
    flex: 1;
    min-width: 140px;
    padding: 15px 20px;
    border: none;
    background: white;
    color: var(--cpj-text-light);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 5px;
}

.cpj-tab-btn::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    height: 3px;
    background: var(--cpj-primary);
    transform: scaleX(0);
    transition: transform 0.3s ease;
}

.cpj-tab-btn:hover {
    background: var(--cpj-background);
    color: var(--cpj-text);
}

.cpj-tab-btn.active {
    color: var(--cpj-primary);
    background: var(--cpj-light);
}

.cpj-tab-btn.active::after {
    transform: scaleX(1);
}

.cpj-tab-btn i {
    font-size: 20px;
    margin-bottom: 2px;
}

/* ========================================
   TAB CONTENT
======================================== */

.cpj-tab-content-container {
    flex: 1;
    position: relative;
    overflow: hidden;
}

.cpj-tab-content {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s ease;
    overflow-y: auto;
    padding: 0;
    pointer-events: none;
}

.cpj-tab-content.active {
    opacity: 1;
    transform: translateX(0);
    pointer-events: all;
}

.cpj-tab-inner {
    padding: 30px;
    max-width: 1200px;
    margin: 0 auto;
}

/* ========================================
   TAB HEADERS
======================================== */

.cpj-tab-header {
    text-align: center;
    margin-bottom: 40px;
    padding-bottom: 20px;
    border-bottom: 1px solid var(--cpj-border);
}

.cpj-tab-title {
    font-size: 32px;
    color: var(--cpj-dark);
    margin: 0 0 10px 0;
    font-weight: 600;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1);
}

.cpj-tab-description {
    font-size: 16px;
    color: var(--cpj-text-light);
    margin: 0;
    max-width: 600px;
    margin: 0 auto;
    line-height: 1.5;
}

/* ========================================
   SECTIONS
======================================== */

.cpj-section-subtitle {
    font-size: 20px;
    color: var(--cpj-dark);
    margin: 30px 0 15px 0;
    font-weight: 600;
}

.cpj-section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.cpj-section-title {
    font-size: 24px;
    color: var(--cpj-dark);
    margin: 0;
    font-weight: 600;
}

.cpj-section-actions {
    display: flex;
    align-items: center;
    gap: 15px;
    flex-wrap: wrap;
}

/* ========================================
   FORMS & INPUTS
======================================== */

.cpj-entry-form {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    margin-bottom: 30px;
    border: 1px solid var(--cpj-light);
}

.cpj-form-group {
    margin-bottom: 20px;
}

.cpj-form-row {
    display: flex;
    gap: 20px;
    margin-bottom: 20px;
}

.cpj-form-half {
    flex: 1;
}

.cpj-form-label {
    display: block;
    font-weight: 600;
    color: var(--cpj-text);
    margin-bottom: 8px;
    font-size: 14px;
}

.cpj-form-input,
.cpj-form-textarea,
.cpj-form-select {
    width: 100%;
    padding: 12px 15px;
    border: 2px solid var(--cpj-border);
    border-radius: 8px;
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
    background: white;
}

.cpj-form-input:focus,
.cpj-form-textarea:focus,
.cpj-form-select:focus {
    outline: none;
    border-color: var(--cpj-primary);
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
}

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

.cpj-form-help {
    font-size: 12px;
    color: var(--cpj-text-muted);
    margin-top: 5px;
    display: block;
}

/* ========================================
   RICH TEXT EDITOR
======================================== */

.cpj-editor-group {
    margin-bottom: 25px;
}

.cpj-editor-container {
    border: 2px solid var(--cpj-border);
    border-radius: 12px;
    overflow: hidden;
    background: white;
    transition: border-color 0.3s ease;
}

.cpj-editor-container:focus-within {
    border-color: var(--cpj-primary);
    box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
}

.cpj-editor-toolbar {
    background: var(--cpj-background);
    border-bottom: 1px solid var(--cpj-border);
    padding: 10px 15px;
    display: flex;
    gap: 5px;
    align-items: center;
    flex-wrap: wrap;
}

.cpj-editor-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--cpj-text-light);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.cpj-editor-btn:hover {
    background: var(--cpj-light);
    color: var(--cpj-text);
}

.cpj-editor-btn.active {
    background: var(--cpj-primary);
    color: white;
}

.cpj-editor-separator {
    width: 1px;
    height: 24px;
    background: var(--cpj-border);
    margin: 0 8px;
}

.cpj-editor-content {
    min-height: 150px;
    padding: 20px;
    font-size: 16px;
    line-height: 1.6;
    outline: none;
    overflow-y: auto;
    max-height: 400px;
}

.cpj-editor-content:empty::before {
    content: attr(data-placeholder);
    color: var(--cpj-text-muted);
    font-style: italic;
    pointer-events: none;
}

.cpj-editor-footer {
    background: var(--cpj-background);
    border-top: 1px solid var(--cpj-border);
    padding: 12px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cpj-char-count {
    font-size: 12px;
    color: var(--cpj-text-muted);
}

.cpj-editor-actions {
    display: flex;
    gap: 10px;
}

/* ========================================
   BUTTONS
======================================== */

.cpj-btn {
    padding: 10px 20px;
    border: none;
    border-radius: 8px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    text-decoration: none;
    font-family: inherit;
    white-space: nowrap;
}

.cpj-btn i {
    font-size: 16px;
}

.cpj-btn-primary {
    background: var(--cpj-primary);
    color: white;
}

.cpj-btn-primary:hover {
    background: #f589a0;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(247, 161, 178, 0.3);
}

.cpj-btn-secondary {
    background: var(--cpj-light);
    color: var(--cpj-text);
}

.cpj-btn-secondary:hover {
    background: var(--cpj-accent);
    transform: translateY(-1px);
}

.cpj-btn-success {
    background: var(--cpj-success);
    color: white;
}

.cpj-btn-success:hover {
    background: #218838;
    transform: translateY(-1px);
}

.cpj-btn-warning {
    background: var(--cpj-warning);
    color: #212529;
}

.cpj-btn-warning:hover {
    background: #e0a800;
    transform: translateY(-1px);
}

.cpj-btn-danger {
    background: var(--cpj-danger);
    color: white;
}

.cpj-btn-danger:hover {
    background: #c82333;
    transform: translateY(-1px);
}

.cpj-btn-sm {
    padding: 6px 12px;
    font-size: 12px;
}

.cpj-btn-full {
    width: 100%;
    justify-content: center;
}

.cpj-btn:disabled,
.cpj-btn.saving {
    opacity: 0.5;
    cursor: not-allowed;
    transform: none !important;
    pointer-events: none;
}

.cpj-btn.saving {
    position: relative;
}

.cpj-btn.saving::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 16px;
    height: 16px;
    margin: -8px 0 0 -8px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: cpj-spin 1s linear infinite;
}

/* ========================================
   ENTRIES & CARDS
======================================== */

.cpj-entries-container {
    margin-bottom: 30px;
}

.cpj-entry {
    background: white;
    border-radius: 12px;
    padding: 25px;
    margin-bottom: 20px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--cpj-light);
    transition: all 0.3s ease;
}

.cpj-entry:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.cpj-entry-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 15px;
    padding-bottom: 15px;
    border-bottom: 1px solid var(--cpj-light);
}

.cpj-entry-title {
    font-size: 20px;
    color: var(--cpj-dark);
    margin: 0 0 5px 0;
    font-weight: 600;
}

.cpj-entry-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
}

.cpj-entry-date {
    font-size: 14px;
    color: var(--cpj-text-light);
}

.cpj-entry-actions {
    display: flex;
    gap: 5px;
    opacity: 0.7;
    transition: opacity 0.2s ease;
}

.cpj-entry:hover .cpj-entry-actions {
    opacity: 1;
}

.cpj-entry-action {
    width: 32px;
    height: 32px;
    border: 1px solid #ddd;
    background: #f8f9fa;
    color: #666;
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
}

.cpj-entry-action:hover {
    background: var(--cpj-light);
    color: var(--cpj-text);
}

.cpj-edit-entry:hover {
    background: var(--cpj-primary);
    color: white;
}

.cpj-delete-entry:hover {
    background: #e74c3c;
    color: white;
}

.cpj-entry-content {
    font-size: 16px;
    line-height: 1.6;
    color: var(--cpj-text);
}

.cpj-entry-content p {
    margin: 0 0 15px 0;
}

.cpj-entry-content p:last-child {
    margin-bottom: 0;
}

.cpj-entry-footer {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--cpj-light);
}

.cpj-entry-updated {
    color: var(--cpj-text-muted);
    font-style: italic;
}

/* ========================================
   PRAYER REQUESTS
======================================== */

.cpj-prayers-container {
    display: grid;
    gap: 20px;
    margin-bottom: 30px;
}

.cpj-prayer-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border-left: 4px solid var(--cpj-primary);
    transition: all 0.3s ease;
}

.cpj-prayer-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.cpj-prayer-card.cpj-prayer-answered {
    border-left-color: var(--cpj-success);
    background: linear-gradient(135deg, #f8fff8 0%, white 100%);
}

.cpj-prayer-card.cpj-prayer-starred {
    border-left-color: var(--cpj-warning);
    background: linear-gradient(135deg, #fffdf0 0%, white 100%);
}

.cpj-prayer-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.cpj-prayer-status {
    display: flex;
    gap: 10px;
}

.cpj-status-badge {
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 5px;
}

.cpj-status-answered {
    background: rgba(40, 167, 69, 0.1);
    color: var(--cpj-success);
}

.cpj-status-ongoing {
    background: rgba(23, 162, 184, 0.1);
    color: var(--cpj-info);
}

.cpj-status-starred {
    background: rgba(255, 193, 7, 0.1);
    color: var(--cpj-warning);
}

.cpj-prayer-date {
    font-size: 14px;
    color: var(--cpj-text-light);
}

.cpj-prayer-content {
    font-size: 16px;
    line-height: 1.6;
    margin-bottom: 15px;
}

.cpj-prayer-update {
    background: var(--cpj-background);
    padding: 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    border-left: 3px solid var(--cpj-accent);
}

.cpj-prayer-update strong {
    color: var(--cpj-dark);
}

.cpj-update-date {
    color: var(--cpj-text-muted);
    font-style: italic;
}

.cpj-prayer-answered-notice {
    background: rgba(40, 167, 69, 0.1);
    color: var(--cpj-success);
    padding: 12px 15px;
    border-radius: 8px;
    margin-bottom: 15px;
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 500;
}

.cpj-prayer-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 20px;
    padding-top: 15px;
    border-top: 1px solid var(--cpj-light);
}

.cpj-action-group {
    display: flex;
    gap: 5px;
}

.cpj-action-btn {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--cpj-text-light);
    border-radius: 6px;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cpj-action-btn:hover {
    background: var(--cpj-light);
    color: var(--cpj-text);
}

.cpj-action-btn.cpj-starred {
    color: var(--cpj-warning);
    background: rgba(255, 193, 7, 0.1);
}

.cpj-action-btn.cpj-answered {
    color: var(--cpj-success);
    background: rgba(40, 167, 69, 0.1);
}

/* ========================================
   NOVENAS
======================================== */

.cpj-novenas-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.cpj-novena-card {
    background: white;
    border-radius: 12px;
    padding: 25px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    border: 1px solid var(--cpj-light);
    transition: all 0.3s ease;
}

.cpj-novena-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15);
}

.cpj-novena-card.cpj-status-Completed {
    background: linear-gradient(135deg, #f8fff8 0%, white 100%);
    border-color: var(--cpj-success);
}

.cpj-novena-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
}

.cpj-novena-status-badge {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.cpj-novena-status-badge.cpj-status-Started {
    background: rgba(23, 162, 184, 0.1);
    color: var(--cpj-info);
}

.cpj-novena-status-badge.cpj-status-Ongoing {
    background: rgba(247, 161, 178, 0.1);
    color: var(--cpj-primary);
}

.cpj-novena-status-badge.cpj-status-Completed {
    background: rgba(40, 167, 69, 0.1);
    color: var(--cpj-success);
}

.cpj-novena-status-badge.cpj-status-Paused {
    background: rgba(255, 193, 7, 0.1);
    color: var(--cpj-warning);
}

.cpj-novena-title {
    font-size: 18px;
    color: var(--cpj-dark);
    margin: 0 0 10px 0;
    font-weight: 600;
}

.cpj-novena-description {
    color: var(--cpj-text-light);
    margin-bottom: 15px;
    line-height: 1.5;
}

.cpj-novena-progress {
    margin-bottom: 15px;
}

.cpj-progress-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
}

.cpj-progress-text {
    font-size: 14px;
    color: var(--cpj-text);
    font-weight: 500;
}

.cpj-progress-percentage {
    font-size: 12px;
    color: var(--cpj-text-light);
}

.cpj-progress-bar {
    height: 8px;
    background: var(--cpj-light);
    border-radius: 4px;
    overflow: hidden;
}

.cpj-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, var(--cpj-primary), var(--cpj-dark));
    border-radius: 4px;
    transition: width 0.3s ease;
}

.cpj-novena-dates {
    margin-bottom: 20px;
}

.cpj-date-info {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: var(--cpj-text-light);
    margin-bottom: 5px;
}

.cpj-novena-footer {
    padding-top: 15px;
    border-top: 1px solid var(--cpj-light);
}

.cpj-day-controls {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 15px;
    margin-bottom: 15px;
}

.cpj-day-display {
    font-weight: 600;
    color: var(--cpj-dark);
    min-width: 60px;
    text-align: center;
}

.cpj-status-controls {
    display: flex;
    gap: 10px;
    justify-content: center;
    flex-wrap: wrap;
}

.cpj-completion-message {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: var(--cpj-success);
    font-weight: 500;
    padding: 15px;
    background: rgba(40, 167, 69, 0.1);
    border-radius: 8px;
}

/* ========================================
   SEARCH & FILTERS
======================================== */

.cpj-search-box {
    position: relative;
    display: flex;
    align-items: center;
}

.cpj-search-input {
    padding: 8px 35px 8px 12px;
    border: 2px solid var(--cpj-border);
    border-radius: 20px;
    font-size: 14px;
    width: 200px;
    transition: all 0.3s ease;
}

.cpj-search-input:focus {
    outline: none;
    border-color: var(--cpj-primary);
    width: 250px;
}

.cpj-search-icon {
    position: absolute;
    right: 12px;
    color: var(--cpj-text-muted);
    pointer-events: none;
}

.cpj-filter-tabs {
    display: flex;
    gap: 5px;
    border-radius: 8px;
    background: var(--cpj-background);
    padding: 4px;
}

.cpj-filter-btn,
.cpj-novena-filter {
    padding: 8px 16px;
    border: none;
    background: transparent;
    color: var(--cpj-text-light);
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.cpj-filter-btn:hover,
.cpj-novena-filter:hover {
    background: white;
    color: var(--cpj-text);
}

.cpj-filter-btn.active,
.cpj-novena-filter.active {
    background: var(--cpj-primary);
    color: white;
}

.cpj-count {
    background: rgba(255, 255, 255, 0.2);
    padding: 2px 6px;
    border-radius: 10px;
    font-size: 12px;
    font-weight: 600;
}

.cpj-filter-btn.active .cpj-count,
.cpj-novena-filter.active .cpj-count {
    background: rgba(255, 255, 255, 0.3);
}

/* ========================================
   MODALS
======================================== */

.cpj-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    padding: 20px;
}

.cpj-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.cpj-modal {
    background: white;
    border-radius: 12px;
    max-width: 500px;
    width: 100%;
    max-height: 90vh;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
}

.cpj-modal-overlay.active .cpj-modal {
    transform: scale(1) translateY(0);
}

.cpj-modal-header {
    padding: 25px 25px 15px 25px;
    border-bottom: 1px solid var(--cpj-light);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cpj-modal-title {
    font-size: 24px;
    color: var(--cpj-dark);
    margin: 0;
    font-weight: 600;
}

.cpj-modal-close {
    width: 36px;
    height: 36px;
    border: none;
    background: transparent;
    color: var(--cpj-text-light);
    font-size: 24px;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cpj-modal-close:hover {
    background: var(--cpj-light);
    color: var(--cpj-text);
}

.cpj-modal-body {
    padding: 25px;
    max-height: 60vh;
    overflow-y: auto;
}

.cpj-modal-footer {
    padding: 15px 25px 25px 25px;
    border-top: 1px solid var(--cpj-light);
    display: flex;
    justify-content: flex-end;
    gap: 10px;
}

/* ========================================
   AUTHENTICATION FORMS
======================================== */

.cpj-auth-modal {
    max-width: 450px;
}

.cpj-auth-notice {
    text-align: center;
    margin-bottom: 25px;
    padding: 20px;
    background: var(--cpj-light);
    border-radius: 8px;
}

.cpj-auth-notice p {
    margin: 0;
    color: var(--cpj-text);
    font-size: 16px;
}

.cpj-auth-tabs {
    display: flex;
    margin-bottom: 25px;
    border-radius: 8px;
    background: var(--cpj-background);
    padding: 4px;
}

.cpj-auth-tab-btn {
    flex: 1;
    padding: 12px 20px;
    border: none;
    background: transparent;
    color: var(--cpj-text-light);
    font-size: 16px;
    font-weight: 500;
    cursor: pointer;
    border-radius: 6px;
    transition: all 0.2s ease;
}

.cpj-auth-tab-btn:hover {
    background: white;
    color: var(--cpj-text);
}

.cpj-auth-tab-btn.active {
    background: var(--cpj-primary);
    color: white;
}

.cpj-auth-form {
    display: none;
}

.cpj-auth-form.active {
    display: block;
}

/* ========================================
   FOOTER
======================================== */

.cpj-footer {
    background: white;
    border-top: 2px solid var(--cpj-light);
    padding: 15px 30px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cpj-quick-actions {
    display: flex;
    gap: 10px;
    align-items: center;
}

.cpj-quick-save {
    position: relative;
}

.cpj-autosave-status {
    display: flex;
    align-items: center;
}

.cpj-save-indicator {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    color: var(--cpj-text-light);
    transition: all 0.3s ease;
}

.cpj-save-indicator.saving {
    color: var(--cpj-warning);
}

.cpj-save-indicator.saved {
    color: var(--cpj-success);
}

.cpj-save-indicator.error {
    color: var(--cpj-danger);
}

/* ========================================
   NOTIFICATIONS
======================================== */

.cpj-notifications-container {
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 10001;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.cpj-notification {
    background: white;
    border-radius: 8px;
    padding: 15px 20px;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    border-left: 4px solid var(--cpj-primary);
    max-width: 400px;
    pointer-events: all;
    transform: translateX(100px);
    opacity: 0;
    transition: all 0.3s ease;
}

.cpj-notification.show {
    transform: translateX(0);
    opacity: 1;
}

.cpj-notification.success {
    border-left-color: var(--cpj-success);
}

.cpj-notification.error {
    border-left-color: var(--cpj-danger);
}

.cpj-notification.warning {
    border-left-color: var(--cpj-warning);
}

.cpj-notification.info {
    border-left-color: var(--cpj-info);
}

.cpj-notification-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.cpj-notification-title {
    font-weight: 600;
    font-size: 14px;
    color: var(--cpj-text);
}

.cpj-notification-close {
    background: none;
    border: none;
    color: var(--cpj-text-light);
    cursor: pointer;
    font-size: 16px;
    padding: 0;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.cpj-notification-message {
    font-size: 14px;
    color: var(--cpj-text-light);
    margin: 0;
}

/* ========================================
   EMPTY STATES
======================================== */

.cpj-empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--cpj-text-light);
}

.cpj-empty-icon {
    font-size: 64px;
    color: var(--cpj-accent);
    margin-bottom: 20px;
}

.cpj-empty-state h4 {
    font-size: 24px;
    color: var(--cpj-dark);
    margin: 0 0 15px 0;
    font-weight: 600;
}

.cpj-empty-state p {
    font-size: 16px;
    margin: 0 0 25px 0;
    max-width: 500px;
    margin-left: auto;
    margin-right: auto;
    line-height: 1.5;
}

.cpj-empty-suggestions {
    max-width: 400px;
    margin: 0 auto;
    text-align: left;
}

.cpj-empty-suggestions h5 {
    font-size: 16px;
    color: var(--cpj-dark);
    margin: 0 0 10px 0;
    font-weight: 600;
    text-align: center;
}

.cpj-empty-suggestions ul {
    margin: 0;
    padding-left: 20px;
}

.cpj-empty-suggestions li {
    margin-bottom: 8px;
    line-height: 1.4;
}

/* ========================================
   RESPONSIVE DESIGN - BEAUTIFUL MOBILE
======================================== */

/* Mobile-First Approach: Enhanced mobile experience */
@media (max-width: 768px) {
    #cpj-prayer-journal {
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
        height: 100vh;
        width: 100vw;
        max-width: 100vw;
        box-shadow: none;
        background: linear-gradient(135deg, #f8f4f6 0%, #f4e1e6 100%);
        display: flex;
        flex-direction: column;
        overflow-x: hidden;
        overflow-y: hidden;
        border: 4px solid var(--cpj-primary);
        border-left: 8px solid var(--cpj-dark);
        position: relative;
    }
    
    /* Add book-like binding effect */
    #cpj-prayer-journal::before {
        content: '';
        position: absolute;
        left: 0;
        top: 0;
        bottom: 0;
        width: 8px;
        background: linear-gradient(180deg, 
            var(--cpj-primary) 0%, 
            var(--cpj-secondary) 25%, 
            var(--cpj-dark) 50%, 
            var(--cpj-secondary) 75%, 
            var(--cpj-primary) 100%);
        z-index: 1;
    }
    
    /* Add subtle spine lines for book effect */
    #cpj-prayer-journal::after {
        content: '';
        position: absolute;
        left: 2px;
        top: 10%;
        bottom: 10%;
        width: 1px;
        background: rgba(255, 255, 255, 0.3);
        box-shadow: 
            2px 0 0 rgba(255, 255, 255, 0.2),
            4px 0 0 rgba(255, 255, 255, 0.1);
        z-index: 2;
    }
    
    /* Prevent any horizontal scrolling globally */
    * {
        max-width: 100%;
        box-sizing: border-box;
    }
    
    /* Ensure containers use full width */
    .cpj-entries-container,
    .cpj-prayers-container,
    .cpj-section-header,
    .cpj-editor-actions,
    .cpj-filter-tabs,
    .cpj-section-actions {
        width: 100%;
        overflow-x: hidden;
    }
    
    /* Fix filter tabs overflow */
    .cpj-filter-tabs {
        display: flex;
        flex-wrap: wrap;
        gap: 4px;
        background: var(--cpj-background);
        padding: 6px;
        border-radius: 8px;
        justify-content: center;
    }
    
    .cpj-filter-btn,
    .cpj-novena-filter {
        padding: 6px 8px;
        font-size: 9px;
        font-weight: 600;
        flex: 1;
        min-width: 0;
        text-align: center;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        border-radius: 6px;
    }
    
    .cpj-count {
        font-size: 8px;
        padding: 1px 4px;
        border-radius: 8px;
        margin-left: 2px;
    }
    
    /* Enhanced Mobile Header */
    .cpj-header {
        padding: 15px 20px 5px 28px; /* Reduced bottom padding to give user status more space */
        border-radius: 0;
        background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 50%, var(--cpj-accent) 100%);
        position: relative;
        overflow: visible; /* Allow user status to extend if needed */
        z-index: 3;
    }
    
    .cpj-header::before {
        opacity: 0.3;
    }
    
    .cpj-scripture-quote {
        padding: 15px;
        margin-bottom: 15px;
        border-radius: 12px;
    }
    
    .cpj-quote-text {
        font-size: 15px;
        line-height: 1.4;
        margin-bottom: 8px;
    }
    
    .cpj-quote-reference {
        font-size: 12px;
    }
    
    /* Prominent User Status - Always visible */
    .cpj-user-status {
        justify-content: center;
        margin-top: 20px;
        margin-bottom: 25px;
        position: relative;
        z-index: 100;
        padding: 12px 20px;
        background: rgba(255, 255, 255, 0.2);
        border-radius: 15px;
        margin-left: 10px;
        margin-right: 10px;
        border: 2px solid rgba(255, 255, 255, 0.3);
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    }
    
    .cpj-user-profile {
        padding: 6px 12px;
        border-radius: 20px;
        gap: 8px;
    }
    
    .cpj-user-avatar {
        width: 32px;
        height: 32px;
        font-size: 14px;
    }
    
    .cpj-welcome-text {
        font-size: 11px;
    }
    
    .cpj-user-name {
        font-size: 13px;
    }
    
    /* Beautiful Mobile Tab Navigation */
    .cpj-tab-navigation {
        background: white;
        border-bottom: 1px solid var(--cpj-light);
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
        position: sticky;
        top: 0;
        z-index: 99; /* Lower than user status */
        padding: 8px;
        display: flex;
        gap: 4px;
        overflow-x: auto;
        scrollbar-width: none;
        -ms-overflow-style: none;
        margin-top: 10px; /* Space from user status */
    }
    
    .cpj-tab-navigation::-webkit-scrollbar {
        display: none;
    }
    
    .cpj-tab-btn {
        min-width: 85px;
        flex-shrink: 0;
        padding: 10px 6px;
        font-size: 10px;
        font-weight: 600;
        border-radius: 12px;
        margin: 0;
        text-align: center;
        line-height: 1.1;
        background: rgba(244, 225, 230, 0.3);
        color: var(--cpj-text-light);
        border: 1px solid rgba(227, 200, 228, 0.2);
        transition: all 0.3s ease;
    }
    
    .cpj-tab-btn i {
        font-size: 14px;
        margin-bottom: 2px;
        display: block;
    }
    
    .cpj-tab-btn.active {
        background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
        color: white;
        transform: translateY(-1px);
        box-shadow: 0 4px 12px rgba(247, 161, 178, 0.3);
        border-color: var(--cpj-primary);
    }
    
    /* Mobile Content Layout - Full Screen Usage */
    .cpj-main-content {
        flex: 1;
        display: flex;
        flex-direction: column;
        overflow: hidden;
        margin-left: 8px; /* Account for book binding */
        position: relative;
        z-index: 3;
    }
    
    .cpj-tab-content-container {
        flex: 1;
        overflow: hidden;
    }
    
    .cpj-tab-content {
        height: 100%;
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    
    .cpj-tab-inner {
        padding: 10px;
        background: transparent;
        width: 100%;
        max-width: 100vw;
        overflow-x: hidden;
        min-height: 100%;
        display: flex;
        flex-direction: column;
    }
    
    .cpj-tab-header {
        text-align: center;
        margin-bottom: 25px;
        padding: 20px 15px;
        background: white;
        border-radius: 16px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
        border: 1px solid rgba(247, 161, 178, 0.1);
    }
    
    .cpj-header-top {
        margin-bottom: 15px;
        justify-content: center;
        gap: 15px;
    }
    
    .cpj-tab-title {
        font-size: 22px;
        margin-bottom: 8px;
        background: linear-gradient(135deg, var(--cpj-primary), var(--cpj-dark));
        -webkit-background-clip: text;
        -webkit-text-fill-color: transparent;
        background-clip: text;
    }
    
    .cpj-tab-description {
        font-size: 14px;
        line-height: 1.4;
        color: var(--cpj-text-light);
    }
    
    .cpj-info-toggle {
        width: 28px;
        height: 28px;
        font-size: 14px;
        background: rgba(247, 161, 178, 0.15);
        border: 1px solid rgba(247, 161, 178, 0.3);
    }
    
    .cpj-info-box {
        margin-top: 15px;
        padding: 15px;
        border-radius: 12px;
        background: linear-gradient(135deg, rgba(244, 225, 230, 0.3), rgba(227, 200, 228, 0.2));
    }
    
    .cpj-info-content h4 {
        font-size: 14px;
        margin-bottom: 10px;
    }
    
    .cpj-info-content p {
        font-size: 13px;
        margin: 6px 0;
    }
    
    /* Enhanced Mobile Forms */
    .cpj-entry-form {
        background: white;
        border-radius: 16px;
        padding: 15px;
        margin-bottom: 15px;
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
        border: 1px solid rgba(247, 161, 178, 0.15);
        width: 100%;
        box-sizing: border-box;
    }
    
    .cpj-form-label {
        font-size: 13px;
        font-weight: 600;
        margin-bottom: 6px;
        color: var(--cpj-dark);
    }
    
    .cpj-form-input {
        padding: 12px 15px;
        font-size: 16px; /* Prevents zoom on iOS */
        border: 2px solid rgba(227, 200, 228, 0.3);
        border-radius: 12px;
        background: rgba(255, 255, 255, 0.9);
        transition: all 0.3s ease;
    }
    
    .cpj-form-input:focus {
        border-color: var(--cpj-primary);
        background: white;
        box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.1);
        transform: translateY(-1px);
    }
    
    /* Beautiful Mobile Editor */
    .cpj-editor-container {
        border: 2px solid rgba(227, 200, 228, 0.3);
        border-radius: 16px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.05);
        background: white;
    }
    
    .cpj-editor-container:focus-within {
        border-color: var(--cpj-primary);
        box-shadow: 0 6px 20px rgba(247, 161, 178, 0.15);
        transform: translateY(-1px);
    }
    
    .cpj-editor-toolbar {
        background: linear-gradient(135deg, #f8f9fa 0%, #f1f3f4 100%);
        padding: 8px 12px;
        flex-wrap: wrap;
        gap: 4px;
        border-bottom: 1px solid rgba(227, 200, 228, 0.2);
    }
    
    .cpj-editor-btn {
        width: 36px;
        height: 36px;
        border-radius: 8px;
        font-size: 14px;
        transition: all 0.2s ease;
    }
    
    .cpj-editor-btn:hover,
    .cpj-editor-btn:active {
        background: var(--cpj-primary);
        color: white;
        transform: scale(0.95);
    }
    
    .cpj-editor-content {
        min-height: 120px;
        padding: 15px;
        font-size: 16px; /* Prevents zoom on iOS */
        line-height: 1.5;
    }
    
    .cpj-editor-footer {
        background: linear-gradient(135deg, #f8f9fa 0%, #f1f3f4 100%);
        padding: 12px 15px;
        border-top: 1px solid rgba(227, 200, 228, 0.2);
        flex-direction: column;
        gap: 10px;
        align-items: stretch;
    }
    
    .cpj-char-count {
        text-align: center;
        font-size: 11px;
        color: var(--cpj-text-muted);
    }
    
    .cpj-editor-actions {
        justify-content: center;
        gap: 12px;
    }
    
    /* Mobile Buttons - Responsive Text */
    .cpj-btn {
        padding: 8px 12px;
        font-size: 11px;
        font-weight: 600;
        border-radius: 12px;
        min-height: 44px; /* iOS touch target */
        touch-action: manipulation;
        transition: all 0.3s ease;
        white-space: nowrap;
        overflow: hidden;
        text-overflow: ellipsis;
        max-width: 100%;
        box-sizing: border-box;
        display: flex;
        align-items: center;
        justify-content: center;
        gap: 4px;
        line-height: 1.2;
    }
    
    /* Multi-line button text for specific long buttons */
    .cpj-btn.cpj-multiline {
        white-space: normal;
        min-height: 60px;
        padding: 6px 12px;
        flex-direction: column;
        line-height: 1.1;
        gap: 2px;
    }
    
    .cpj-btn.cpj-multiline .cpj-btn-line {
        display: block;
        font-size: 11px;
        font-weight: 600;
        text-align: center;
        line-height: 1.1;
    }
    
    .cpj-btn:active {
        transform: scale(0.97);
    }
    
    .cpj-btn-primary {
        background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
        box-shadow: 0 4px 15px rgba(247, 161, 178, 0.3);
    }
    
    .cpj-btn-primary:hover,
    .cpj-btn-primary:active {
        box-shadow: 0 6px 20px rgba(247, 161, 178, 0.4);
        transform: translateY(-1px);
    }
    
    .cpj-btn-secondary {
        background: white;
        border: 2px solid var(--cpj-light);
        color: var(--cpj-text);
    }
    
    .cpj-btn-full {
        width: 100%;
    }
    
    /* Specific button text fixes */
    .cpj-btn i {
        flex-shrink: 0;
        font-size: 14px;
    }
    
    .cpj-btn-text,
    .cpj-btn span {
        flex: 1;
        text-align: center;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
    }
    
    /* Fix specific long button texts */
    .cpj-btn:contains("Request Community"),
    .cpj-btn:contains("Start Prayer Tracker"),
    .cpj-btn:contains("Add Prayer Request") {
        font-size: 11px;
        padding: 12px 12px;
    }
    
    /* Center text in buttons with icons */
    .cpj-btn {
        text-align: center;
        line-height: 1.2;
    }
    
    /* Better responsive behavior for action buttons */
    .cpj-editor-actions .cpj-btn,
    .cpj-prayer-actions .cpj-btn,
    .cpj-section-actions .cpj-btn {
        flex: 1;
        min-width: 0;
        font-size: 11px;
    }
    
    /* Fix clear button alignment */
    .cpj-clear-editor,
    .cpj-search-clear {
        display: flex;
        align-items: center;
        justify-content: center;
        text-align: center;
    }
    
    /* Confession tab - Catholic Examination of Conscience button styling */
    .cpj-btn:contains("Catholic Examination of Conscience"),
    a[href*="examination-of-conscience-catholic"] {
        font-size: 22px !important; /* Double the current size */
        line-height: 1.2;
        padding: 15px 20px;
        min-height: 60px;
    }
    
    /* Beautiful Mobile Entries */
    .cpj-entry {
        background: white;
        border-radius: 16px;
        padding: 20px;
        margin-bottom: 15px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
        border: 1px solid rgba(247, 161, 178, 0.1);
        transition: all 0.3s ease;
    }
    
    .cpj-entry:active {
        transform: scale(0.98);
    }
    
    .cpj-entry-header {
        margin-bottom: 12px;
        padding-bottom: 12px;
        border-bottom: 1px solid rgba(247, 161, 178, 0.15);
    }
    
    .cpj-entry-title {
        font-size: 18px;
        margin-bottom: 8px;
        line-height: 1.3;
        color: var(--cpj-dark);
    }
    
    .cpj-entry-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .cpj-entry-date {
        font-size: 12px;
        color: var(--cpj-text-light);
        background: rgba(244, 225, 230, 0.5);
        padding: 3px 8px;
        border-radius: 12px;
    }
    
    .cpj-entry-actions {
        display: flex;
        gap: 8px;
        opacity: 1; /* Always visible on mobile */
    }
    
    .cpj-entry-action {
        width: 36px;
        height: 36px;
        border-radius: 8px;
        font-size: 16px;
        border: 1px solid rgba(227, 200, 228, 0.3);
        background: rgba(244, 225, 230, 0.3);
        transition: all 0.2s ease;
    }
    
    .cpj-entry-action:active {
        transform: scale(0.9);
    }
    
    .cpj-entry-content {
        font-size: 15px;
        line-height: 1.5;
        color: var(--cpj-text);
    }
    
    /* Enhanced Mobile Prayer Cards */
    .cpj-prayer-card {
        background: white;
        border-radius: 16px;
        padding: 18px;
        margin-bottom: 15px;
        box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
        border-left: 4px solid var(--cpj-primary);
        transition: all 0.3s ease;
    }
    
    .cpj-prayer-card:active {
        transform: scale(0.98);
    }
    
    .cpj-request-header {
        flex-direction: column;
        align-items: stretch;
        gap: 10px;
        margin-bottom: 12px;
    }
    
    .cpj-request-actions {
        justify-content: flex-end;
        margin-top: 8px;
        gap: 10px;
    }
    
    .cpj-request-action {
        padding: 8px 12px;
        font-size: 14px;
        min-width: 40px;
        min-height: 40px;
        border-radius: 8px;
        border: 1px solid rgba(227, 200, 228, 0.3);
        background: rgba(244, 225, 230, 0.3);
    }
    
    .cpj-request-action:active {
        transform: scale(0.9);
    }
    
    .cpj-request-content {
        font-size: 14px;
        padding: 12px;
        border-radius: 12px;
        background: rgba(244, 225, 230, 0.2);
        border-left: 3px solid var(--cpj-primary);
    }
    
    /* Mobile Search Enhancement */
    .cpj-search-section {
        margin: 15px 0;
        padding: 0;
    }
    
    .cpj-search-box {
        max-width: none;
        margin: 0;
    }
    
    .cpj-search-input {
        width: 100%;
        padding: 12px 40px 12px 16px;
        font-size: 16px; /* Prevents zoom on iOS */
        border: 2px solid rgba(227, 200, 228, 0.3);
        border-radius: 25px;
        background: white;
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
    }
    
    .cpj-search-input:focus {
        border-color: var(--cpj-primary);
        box-shadow: 0 4px 15px rgba(247, 161, 178, 0.2);
        transform: translateY(-1px);
    }
    
    .cpj-search-clear {
        width: 32px;
        height: 32px;
        right: 6px;
        background: rgba(227, 200, 228, 0.2);
        border-radius: 50%;
    }
    
    .cpj-search-clear:active {
        transform: translateY(-50%) scale(0.9);
    }
    
    /* Section Headers */
    .cpj-section-header {
        flex-direction: column;
        align-items: stretch;
        gap: 12px;
        margin-bottom: 15px;
        width: 100%;
        padding: 0;
    }
    
    .cpj-section-title {
        font-size: 18px;
        text-align: center;
        color: var(--cpj-dark);
        margin: 0;
    }
    
    .cpj-section-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 8px;
        width: 100%;
    }
    
    /* Ensure action buttons fill width properly */
    .cpj-section-actions .cpj-btn {
        width: 100%;
        margin: 0;
    }
    
    /* Mobile Notifications */
    .cpj-notifications-container {
        top: 10px;
        right: 10px;
        left: 10px;
        z-index: 10002;
    }
    
    .cpj-notification {
        max-width: none;
        border-radius: 12px;
        padding: 12px 16px;
        box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
    }
    
    .cpj-notification-title {
        font-size: 13px;
    }
    
    .cpj-notification-message {
        font-size: 12px;
    }
    
    /* Mobile Modals */
    .cpj-modal {
        margin: 15px;
        max-width: calc(100vw - 30px);
        max-height: calc(100vh - 30px);
        border-radius: 16px;
    }
    
    .cpj-modal-header {
        padding: 16px 20px;
        border-radius: 16px 16px 0 0;
    }
    
    .cpj-modal-title {
        font-size: 16px;
    }
    
    .cpj-modal-close {
        width: 32px;
        height: 32px;
        font-size: 20px;
    }
    
    .cpj-modal-content {
        padding: 20px;
        max-height: calc(100vh - 150px);
    }
    
    /* Footer */
    .cpj-footer {
        flex-direction: column;
        gap: 15px;
        padding: 15px 20px;
        background: white;
        border-top: 1px solid rgba(227, 200, 228, 0.3);
    }
    
    .cpj-quick-actions {
        justify-content: center;
        flex-wrap: wrap;
        gap: 12px;
    }
    
    .cpj-save-indicator {
        font-size: 13px;
        padding: 6px 12px;
        background: rgba(244, 225, 230, 0.5);
        border-radius: 20px;
    }
    
    /* Hide text on small buttons */
    .cpj-btn-text {
        display: none;
    }
    
    /* Enhanced touch targets */
    .cpj-tab-btn,
    .cpj-btn,
    .cpj-entry-action,
    .cpj-request-action,
    .cpj-editor-btn {
        min-height: 44px;
        min-width: 44px;
    }
    
    /* Beautiful gradients for backgrounds */
    .cpj-entries-container {
        background: transparent;
    }
    
    /* Smooth scrolling */
    .cpj-tab-content {
        scroll-behavior: smooth;
    }
    
    /* Better spacing */
    .cpj-form-group {
        margin-bottom: 16px;
    }
    
    .cpj-form-row {
        flex-direction: column;
        gap: 12px;
    }
}

/* Ultra Mobile (Very Small Screens) */
@media (max-width: 480px) {
    .cpj-header {
        padding: 12px 15px 15px 23px; /* Accommodate book binding */
    }
    
    .cpj-scripture-quote {
        padding: 12px;
    }
    
    .cpj-quote-text {
        font-size: 14px;
    }
    
    .cpj-quote-reference {
        font-size: 11px;
    }
    
    .cpj-user-profile {
        padding: 4px 10px;
        gap: 6px;
    }
    
    .cpj-user-avatar {
        width: 28px;
        height: 28px;
        font-size: 12px;
    }
    
    .cpj-welcome-text {
        font-size: 10px;
    }
    
    .cpj-user-name {
        font-size: 12px;
    }
    
    /* Extremely compact tabs */
    .cpj-tab-btn {
        min-width: 70px;
        flex-shrink: 0;
        padding: 8px 4px;
        font-size: 9px;
        margin: 0;
        border-radius: 10px;
        line-height: 1.1;
    }
    
    .cpj-tab-btn i {
        font-size: 14px;
        margin-bottom: 2px;
    }
    
    .cpj-tab-inner {
        padding: 12px;
    }
    
    .cpj-tab-header {
        padding: 15px 12px;
        margin-bottom: 20px;
    }
    
    .cpj-tab-title {
        font-size: 20px;
        margin-bottom: 6px;
    }
    
    .cpj-tab-description {
        font-size: 13px;
    }
    
    .cpj-info-toggle {
        width: 26px;
        height: 26px;
        font-size: 12px;
    }
    
    .cpj-info-box {
        padding: 12px;
    }
    
    .cpj-info-content h4 {
        font-size: 13px;
        margin-bottom: 8px;
    }
    
    .cpj-info-content p {
        font-size: 12px;
        margin: 5px 0;
    }
    
    /* Ultra compact forms */
    .cpj-entry-form {
        padding: 15px;
        margin-bottom: 15px;
        border-radius: 14px;
    }
    
    .cpj-form-label {
        font-size: 12px;
        margin-bottom: 5px;
    }
    
    .cpj-form-input {
        padding: 10px 12px;
        font-size: 16px; /* Keep 16px to prevent zoom */
        border-radius: 10px;
    }
    
    /* Compact editor */
    .cpj-editor-container {
        border-radius: 14px;
    }
    
    .cpj-editor-toolbar {
        padding: 6px 10px;
        gap: 3px;
    }
    
    .cpj-editor-btn {
        width: 32px;
        height: 32px;
        font-size: 12px;
        border-radius: 6px;
    }
    
    .cpj-editor-content {
        min-height: 100px;
        padding: 12px;
        font-size: 16px; /* Keep 16px to prevent zoom */
    }
    
    .cpj-editor-footer {
        padding: 10px 12px;
    }
    
    .cpj-char-count {
        font-size: 10px;
    }
    
    .cpj-editor-actions {
        gap: 10px;
    }
    
    /* Compact buttons */
    .cpj-btn {
        padding: 8px 8px;
        font-size: 9px;
        border-radius: 10px;
        min-height: 42px;
        max-width: 100%;
        box-sizing: border-box;
        overflow: hidden;
        text-overflow: ellipsis;
        white-space: nowrap;
        line-height: 1.1;
        gap: 3px;
    }
    
    /* Ultra mobile multi-line buttons */
    .cpj-btn.cpj-multiline {
        min-height: 55px;
        padding: 5px 8px;
        font-size: 10px;
    }
    
    .cpj-btn.cpj-multiline .cpj-btn-line {
        font-size: 10px;
    }
    
    /* Ultra compact entries */
    .cpj-entry {
        padding: 15px;
        margin-bottom: 12px;
        border-radius: 14px;
    }
    
    .cpj-entry-header {
        margin-bottom: 10px;
        padding-bottom: 10px;
    }
    
    .cpj-entry-title {
        font-size: 16px;
        margin-bottom: 6px;
    }
    
    .cpj-entry-meta {
        gap: 6px;
    }
    
    .cpj-entry-date {
        font-size: 11px;
        padding: 2px 6px;
    }
    
    .cpj-entry-actions {
        gap: 6px;
    }
    
    .cpj-entry-action {
        width: 32px;
        height: 32px;
        font-size: 14px;
        border-radius: 6px;
    }
    
    .cpj-entry-content {
        font-size: 14px;
    }
    
    /* Compact prayer cards */
    .cpj-prayer-card {
        padding: 15px;
        margin-bottom: 12px;
        border-radius: 14px;
    }
    
    .cpj-request-header {
        gap: 8px;
        margin-bottom: 10px;
    }
    
    .cpj-request-actions {
        gap: 8px;
    }
    
    .cpj-request-action {
        padding: 6px 10px;
        font-size: 13px;
        min-width: 36px;
        min-height: 36px;
        border-radius: 6px;
    }
    
    .cpj-request-content {
        font-size: 13px;
        padding: 10px;
        border-radius: 10px;
    }
    
    /* Compact search */
    .cpj-search-section {
        margin: 12px 0;
    }
    
    .cpj-search-input {
        padding: 10px 36px 10px 14px;
        font-size: 16px; /* Keep 16px to prevent zoom */
        border-radius: 20px;
    }
    
    .cpj-search-clear {
        width: 28px;
        height: 28px;
        right: 5px;
    }
    
    /* Compact sections */
    .cpj-section-header {
        gap: 12px;
        margin-bottom: 15px;
    }
    
    .cpj-section-title {
        font-size: 18px;
    }
    
    .cpj-section-actions {
        gap: 8px;
    }
    
    /* Compact notifications */
    .cpj-notifications-container {
        top: 8px;
        right: 8px;
        left: 8px;
    }
    
    .cpj-notification {
        padding: 10px 12px;
        border-radius: 10px;
    }
    
    .cpj-notification-title {
        font-size: 12px;
    }
    
    .cpj-notification-message {
        font-size: 11px;
    }
    
    /* Compact modals */
    .cpj-modal {
        margin: 10px;
        max-width: calc(100vw - 20px);
        max-height: calc(100vh - 20px);
        border-radius: 14px;
    }
    
    .cpj-modal-header {
        padding: 12px 15px;
        border-radius: 14px 14px 0 0;
    }
    
    .cpj-modal-title {
        font-size: 15px;
    }
    
    .cpj-modal-close {
        width: 28px;
        height: 28px;
        font-size: 18px;
    }
    
    .cpj-modal-content {
        padding: 15px;
        max-height: calc(100vh - 120px);
    }
    
    /* Compact footer */
    .cpj-footer {
        padding: 12px 15px;
        gap: 12px;
    }
    
    .cpj-quick-actions {
        gap: 10px;
    }
    
    .cpj-save-indicator {
        font-size: 12px;
        padding: 4px 10px;
    }
    
    /* Ensure touch targets remain accessible */
    .cpj-tab-btn,
    .cpj-btn,
    .cpj-entry-action,
    .cpj-request-action,
    .cpj-editor-btn {
        min-height: 42px;
        min-width: 42px;
    }
    
    /* Better form spacing */
    .cpj-form-group {
        margin-bottom: 14px;
    }
    
    .cpj-form-row {
        gap: 10px;
    }
}

/* ========================================
   MOBILE-SPECIFIC ENHANCEMENTS
======================================== */

/* Mobile-only styles for enhanced experience */
@media (max-width: 768px) and (hover: none) {
    /* Touch-specific enhancements */
    .cpj-entry,
    .cpj-prayer-card {
        -webkit-tap-highlight-color: rgba(247, 161, 178, 0.1);
        tap-highlight-color: rgba(247, 161, 178, 0.1);
    }
    
    /* Enhanced touch feedback */
    .cpj-btn:active,
    .cpj-tab-btn:active,
    .cpj-entry-action:active,
    .cpj-request-action:active {
        background: var(--cpj-primary);
        color: white;
        transform: scale(0.95);
        transition: all 0.1s ease;
    }
    
    /* Better scrolling for mobile */
    .cpj-tab-content {
        -webkit-overflow-scrolling: touch;
        overscroll-behavior: contain;
    }
    
    /* Prevent text selection on UI elements */
    .cpj-tab-btn,
    .cpj-btn,
    .cpj-entry-action,
    .cpj-request-action,
    .cpj-editor-btn {
        -webkit-user-select: none;
        -moz-user-select: none;
        -ms-user-select: none;
        user-select: none;
    }
    
    /* Enhanced focus states for mobile */
    .cpj-form-input:focus,
    .cpj-editor-content:focus,
    .cpj-search-input:focus {
        outline: none;
        border-color: var(--cpj-primary);
        box-shadow: 0 0 0 3px rgba(247, 161, 178, 0.2);
        transform: translateY(-1px);
        background: white;
    }
    
    /* Mobile-optimized animations */
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-entry-form {
        will-change: transform;
        backface-visibility: hidden;
        -webkit-backface-visibility: hidden;
    }
    
    /* Safe area support for newer mobile devices */
    .cpj-header {
        padding-top: max(15px, env(safe-area-inset-top));
    }
    
    .cpj-footer {
        padding-bottom: max(15px, env(safe-area-inset-bottom));
    }
    
    .cpj-tab-navigation {
        position: sticky;
        top: env(safe-area-inset-top, 0);
    }
}

/* Landscape mobile optimizations */
@media (max-width: 968px) and (orientation: landscape) and (max-height: 500px) {
    .cpj-header {
        padding: 10px 20px;
    }
    
    .cpj-scripture-quote {
        padding: 10px;
        margin-bottom: 10px;
    }
    
    .cpj-quote-text {
        font-size: 14px;
        margin-bottom: 5px;
    }
    
    .cpj-tab-inner {
        padding: 10px 15px;
    }
    
    .cpj-tab-header {
        margin-bottom: 15px;
        padding: 15px;
    }
    
    .cpj-tab-title {
        font-size: 20px;
        margin-bottom: 6px;
    }
    
    .cpj-entry-form {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .cpj-editor-content {
        min-height: 80px;
    }
}

/* High resolution mobile displays */
@media (max-width: 768px) and (-webkit-min-device-pixel-ratio: 2) {
    /* Crisp rendering for high-DPI screens */
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-entry-form {
        -webkit-font-smoothing: antialiased;
        -moz-osx-font-smoothing: grayscale;
    }
    
    /* Enhanced shadows for retina displays */
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-entry-form,
    .cpj-tab-header {
        box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1), 0 1px 3px rgba(0, 0, 0, 0.08);
    }
    
    .cpj-entry:hover,
    .cpj-prayer-card:hover,
    .cpj-entry-form:focus-within {
        box-shadow: 0 4px 16px rgba(0, 0, 0, 0.12), 0 2px 6px rgba(0, 0, 0, 0.08);
    }
}

/* Dark mode support for mobile */
@media (max-width: 768px) and (prefers-color-scheme: dark) {
    :root {
        --cpj-background: #1a1a1a;
        --cpj-text: #e0e0e0;
        --cpj-text-light: #b0b0b0;
        --cpj-text-muted: #888;
        --cpj-border: #333;
    }
    
    #cpj-prayer-journal {
        background: linear-gradient(135deg, #1a1a1a 0%, #2d1b2f 100%);
    }
    
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-entry-form,
    .cpj-tab-header {
        background: #2a2a2a;
        border-color: #444;
        color: var(--cpj-text);
    }
    
    .cpj-form-input,
    .cpj-editor-content,
    .cpj-search-input {
        background: #333;
        border-color: #555;
        color: var(--cpj-text);
    }
    
    .cpj-form-input:focus,
    .cpj-editor-content:focus,
    .cpj-search-input:focus {
        background: #444;
        border-color: var(--cpj-primary);
    }
}

/* Accessibility enhancements for mobile */
@media (max-width: 768px) {
    /* High contrast mode */
    @media (prefers-contrast: high) {
        .cpj-entry,
        .cpj-prayer-card,
        .cpj-entry-form {
            border-width: 2px;
            border-color: #000;
        }
        
        .cpj-btn-primary {
            background: #000;
            color: #fff;
            border: 2px solid #000;
        }
        
        .cpj-btn-secondary {
            background: #fff;
            color: #000;
            border: 2px solid #000;
        }
    }
    
    /* Reduced motion */
    @media (prefers-reduced-motion: reduce) {
        .cpj-entry,
        .cpj-prayer-card,
        .cpj-btn,
        .cpj-tab-btn {
            transition: none;
            transform: none !important;
            animation: none !important;
        }
        
        .cpj-entry:active,
        .cpj-prayer-card:active,
        .cpj-btn:active {
            transform: none !important;
        }
    }
    
    /* Large text support */
    @media (prefers-font-size: large) {
        .cpj-tab-title {
            font-size: 26px;
        }
        
        .cpj-entry-title {
            font-size: 20px;
        }
        
        .cpj-entry-content,
        .cpj-request-content {
            font-size: 17px;
            line-height: 1.6;
        }
        
        .cpj-form-input,
        .cpj-editor-content {
            font-size: 18px;
        }
    }
}

/* PWA-specific mobile styles */
@media (display-mode: standalone) {
    #cpj-prayer-journal {
        margin: 0;
        border-radius: 0;
        min-height: 100vh;
    }
    
    .cpj-header {
        padding-top: max(15px, env(safe-area-inset-top, 20px));
        border-radius: 0;
    }
    
    .cpj-footer {
        padding-bottom: max(15px, env(safe-area-inset-bottom, 20px));
    }
}

/* ========================================
   UTILITY CLASSES
======================================== */

.cpj-hidden {
    display: none !important;
}

.cpj-invisible {
    visibility: hidden;
}

.cpj-text-center {
    text-align: center;
}

.cpj-text-left {
    text-align: left;
}

.cpj-text-right {
    text-align: right;
}

.cpj-mb-10 {
    margin-bottom: 10px;
}

.cpj-mb-20 {
    margin-bottom: 20px;
}

.cpj-mt-20 {
    margin-top: 20px;
}

.cpj-fade-in {
    animation: cpj-fadeIn 0.3s ease;
}

@keyframes cpj-fadeIn {
    from { opacity: 0; transform: translateY(10px); }
    to { opacity: 1; transform: translateY(0); }
}

.cpj-pulse {
    animation: cpj-pulse 2s ease-in-out infinite;
}

@keyframes cpj-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* ========================================
   PRINT STYLES
======================================== */

@media print {
    #cpj-prayer-journal {
        box-shadow: none;
        border-radius: 0;
        margin: 0;
    }
    
    .cpj-footer,
    .cpj-tab-navigation,
    .cpj-section-actions,
    .cpj-entry-actions,
    .cpj-prayer-actions,
    .cpj-novena-actions,
    .cpj-editor-toolbar,
    .cpj-editor-footer {
        display: none !important;
    }
    
    .cpj-tab-content {
        position: static;
        opacity: 1;
        transform: none;
        overflow: visible;
    }
    
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-novena-card {
        break-inside: avoid;
        box-shadow: none;
        border: 1px solid var(--cpj-border);
    }
}

/* ========================================
   ACCESSIBILITY
======================================== */

@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
}

.cpj-sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

/* Focus styles for keyboard navigation */
.cpj-tab-btn:focus,
.cpj-btn:focus,
.cpj-form-input:focus,
.cpj-form-textarea:focus,
.cpj-form-select:focus,
.cpj-editor-btn:focus,
.cpj-action-btn:focus {
    outline: 2px solid var(--cpj-primary);
    outline-offset: 2px;
}

.cpj-editor-content:focus {
    outline: 2px solid var(--cpj-primary);
    outline-offset: -2px;
}

/* High contrast mode support */
@media (prefers-contrast: high) {
    :root {
        --cpj-primary: #c1185e;
        --cpj-secondary: #e91e63;
        --cpj-text: #000;
        --cpj-text-light: #333;
        --cpj-border: #666;
    }
    
    .cpj-entry,
    .cpj-prayer-card,
    .cpj-novena-card,
    .cpj-community-card {
        border-width: 2px;
    }
}

/* ==================== COMMUNITY PRAYER CARDS ==================== */

.cpj-community-card {
    background: #ffffff;
    border: 2px solid #e0e0e0;
    border-radius: 12px;
    padding: 20px;
    margin-bottom: 16px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.cpj-community-card:hover {
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
    border-color: var(--cpj-primary);
}

.cpj-community-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(90deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
}

/* Community Card Header */
.cpj-community-header {
    margin-bottom: 16px;
}

.cpj-prayer-progress {
    margin-bottom: 12px;
}

.cpj-progress-bar {
    width: 100%;
    height: 8px;
    background-color: #f5f5f5;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 6px;
}

.cpj-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #ff4444 0%, #ff6666 100%);
    border-radius: 4px;
    transition: width 0.4s ease;
    box-shadow: 0 0 8px rgba(255, 68, 68, 0.4);
}

.cpj-progress-text {
    font-size: 16px;
    color: #ff4444;
    font-weight: 700;
    background: rgba(255, 68, 68, 0.1);
    padding: 4px 12px;
    border-radius: 20px;
    border: 2px solid #ff4444;
    text-align: center;
    display: inline-block;
}

.cpj-community-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px;
}

.cpj-requester-name {
    font-weight: 600;
    color: var(--cpj-primary);
    font-size: 16px;
}

.cpj-request-date {
    font-size: 12px;
    color: #666;
    background: #e9ecef;
    padding: 4px 8px;
    border-radius: 12px;
}

/* Community Card Content */
.cpj-community-content {
    margin-bottom: 16px;
}

.cpj-prayer-intention {
    font-size: 15px;
    line-height: 1.6;
    color: #333;
    margin: 0;
    padding: 16px;
    background: #f8f9fa;
    border-radius: 8px;
    border-left: 4px solid var(--cpj-primary);
    font-style: italic;
    position: relative;
}

.cpj-prayer-intention::before {
    content: '"';
    font-size: 24px;
    color: var(--cpj-primary);
    font-weight: bold;
    position: absolute;
    top: 8px;
    left: 8px;
    line-height: 1;
}

.cpj-prayer-intention::after {
    content: '"';
    font-size: 24px;
    color: var(--cpj-primary);
    font-weight: bold;
    position: absolute;
    bottom: 8px;
    right: 12px;
    line-height: 1;
}

/* Community Card Actions */
.cpj-community-actions {
    display: flex;
    gap: 12px;
    align-items: center;
    flex-wrap: wrap;
}

.cpj-pray-button {
    background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    justify-content: center;
}

.cpj-pray-button:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 30, 99, 0.3);
}

.cpj-pray-button:active {
    transform: translateY(0);
}

.cpj-prayed-button {
    background: linear-gradient(135deg, #4caf50 0%, #66bb6a 100%);
    color: white;
    border: none;
    padding: 12px 20px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 14px;
    cursor: default;
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 1;
    justify-content: center;
    opacity: 0.8;
}

.cpj-view-prayers {
    background: #f8f9fa;
    color: var(--cpj-primary);
    border: 2px solid var(--cpj-primary);
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.cpj-toggle-prayers {
    background: #f8f9fa;
    color: var(--cpj-primary);
    border: 2px solid var(--cpj-primary);
    padding: 10px 16px;
    border-radius: 8px;
    font-weight: 500;
    font-size: 13px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    gap: 6px;
}

.cpj-toggle-prayers:hover {
    background: var(--cpj-primary);
    color: white;
    transform: translateY(-1px);
}

.cpj-toggle-arrow {
    font-size: 10px;
    transition: transform 0.3s ease;
}

/* Prayer Warriors Expandable Section */
.cpj-prayer-warriors-section {
    margin-top: 16px;
    padding: 20px;
    background: #f8f9fa;
    border-radius: 8px;
    border-top: 3px solid var(--cpj-primary);
}

.cpj-warriors-loading {
    text-align: center;
    padding: 20px;
    color: #666;
}

.cpj-loading-spinner::before {
    content: '⏳';
    animation: spin 1s linear infinite;
}

@keyframes spin {
    from { transform: rotate(0deg); }
    to { transform: rotate(360deg); }
}

.cpj-warriors-header {
    margin-bottom: 16px;
    text-align: center;
}

.cpj-warriors-header h4 {
    margin: 0 0 8px 0;
    color: var(--cpj-primary);
    font-size: 18px;
}

.cpj-warriors-header p {
    margin: 0;
    color: #666;
    font-style: italic;
}

.cpj-prayer-warriors-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.cpj-prayer-warrior-item {
    background: white;
    border-radius: 8px;
    margin-bottom: 8px;
    padding: 12px 16px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
    transition: transform 0.2s ease;
}

.cpj-prayer-warrior-item:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.15);
}

.cpj-warrior-info {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 12px;
}

.cpj-warrior-name {
    font-weight: 600;
    color: var(--cpj-primary);
    font-size: 14px;
}

.cpj-prayer-time {
    font-size: 12px;
    color: #666;
    background: #e9ecef;
    padding: 2px 8px;
    border-radius: 12px;
    white-space: nowrap;
}

.cpj-warriors-empty,
.cpj-warriors-error {
    text-align: center;
    padding: 20px;
    color: #666;
}

.cpj-warriors-empty p,
.cpj-warriors-error p {
    margin: 4px 0;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .cpj-prayer-warriors-section {
        padding: 16px;
        margin-top: 12px;
    }
    
    .cpj-warrior-info {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
    
    .cpj-toggle-prayers {
        font-size: 12px;
        padding: 8px 12px;
    }
}

/* Icons for community buttons */
.cpj-pray-button .cpj-icon-rosary::before {
    content: '📿';
}

.cpj-prayed-button .cpj-icon-check::before {
    content: '✅';
}

.cpj-view-prayers .cpj-icon-eye::before {
    content: '👁️';
}

/* Empty state styling */
#cpj-community-empty {
    text-align: center;
    padding: 60px 20px;
    color: var(--cpj-text-light);
}

#cpj-community-empty .cpj-empty-icon {
    font-size: 48px;
    margin-bottom: 16px;
    opacity: 0.6;
}

#cpj-community-empty h3 {
    margin: 0 0 8px 0;
    font-size: 18px;
    color: var(--cpj-text);
}

#cpj-community-empty p {
    margin: 0;
    font-size: 14px;
}

/* Responsive design for community cards */
@media (max-width: 768px) {
    .cpj-community-card {
        padding: 16px;
        margin-bottom: 12px;
    }
    
    .cpj-community-meta {
        flex-direction: column;
        align-items: flex-start;
        gap: 6px;
    }
    
    .cpj-community-actions {
        flex-direction: column;
        gap: 8px;
    }
    
    .cpj-pray-button,
    .cpj-prayed-button {
        width: 100%;
    }
    
    .cpj-prayer-intention {
        padding: 12px;
        font-size: 14px;
    }
    
    .cpj-prayer-intention::before,
    .cpj-prayer-intention::after {
        font-size: 18px;
    }
}

/* Animation for when prayers are submitted */
.cpj-community-card.cpj-prayer-submitted {
    animation: prayerSubmitted 0.6s ease-out;
}

@keyframes prayerSubmitted {
    0% { transform: scale(1); }
    50% { transform: scale(1.02); background-color: rgba(76, 175, 80, 0.1); }
    100% { transform: scale(1); }
}

/* ==================== MODAL STYLES ==================== */

.cpj-modal-overlay {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    width: 100% !important;
    height: 100% !important;
    background: rgba(0, 0, 0, 0.8) !important;
    backdrop-filter: blur(4px);
    z-index: 999999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 20px !important;
}

.cpj-modal {
    background: white !important;
    border-radius: 12px !important;
    max-width: 600px !important;
    width: 100% !important;
    max-height: 80vh !important;
    overflow: hidden !important;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.5) !important;
    animation: modalSlideIn 0.3s ease-out !important;
    z-index: 1000000 !important;
    position: relative !important;
}

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

.cpj-modal-header {
    padding: 20px;
    border-bottom: 1px solid #e0e0e0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    background: linear-gradient(135deg, var(--cpj-primary) 0%, var(--cpj-secondary) 100%);
    color: white;
}

.cpj-modal-title {
    margin: 0;
    font-size: 18px;
    font-weight: 600;
}

.cpj-modal-close {
    background: none;
    border: none;
    font-size: 24px;
    color: white;
    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;
}

.cpj-modal-close:hover {
    background-color: rgba(255, 255, 255, 0.2);
}

.cpj-modal-content {
    padding: 20px;
    max-height: 60vh;
    overflow-y: auto;
}

/* Prayer details modal specific styles */
.cpj-prayer-details h3 {
    margin: 0 0 15px 0;
    color: var(--cpj-primary);
}

.cpj-intention-text {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 8px;
    border-left: 4px solid var(--cpj-primary);
    font-style: italic;
    margin-bottom: 20px;
}

.cpj-prayer-list h4 {
    margin: 0 0 15px 0;
    color: #333;
}

.cpj-prayer-warriors {
    list-style: none;
    padding: 0;
    margin: 0;
}

.cpj-prayer-warrior {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #f8f9fa;
    border-radius: 8px;
    margin-bottom: 8px;
}

.cpj-prayer-warrior .cpj-icon-rosary::before {
    content: '📿';
    font-size: 16px;
}

.cpj-warrior-name {
    font-weight: 600;
    color: var(--cpj-primary);
    flex: 1;
}

.cpj-prayer-time {
    font-size: 12px;
    color: #666;
    background: #e9ecef;
    padding: 2px 8px;
    border-radius: 12px;
}

/* Responsive modal */
@media (max-width: 768px) {
    .cpj-modal {
        margin: 10px;
        max-height: 90vh;
    }
    
    .cpj-modal-header,
    .cpj-modal-content {
        padding: 15px;
    }
    
    .cpj-prayer-warrior {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }
}
