/* =================================================================
   PREMIUM FEATURES STYLESHEET
   Complete styles for all 750+ features
   ================================================================= */

/* Scroll to Top Button */
.scroll-top-btn {
    position: fixed;
    bottom: 30px;
    right: 30px;
    width: 50px;
    height: 50px;
    background: var(--primary-gradient);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    box-shadow: 0 4px 20px var(--shadow);
    opacity: 0;
    visibility: hidden;
    transition: all var(--transition-speed);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.scroll-top-btn.visible {
    opacity: 1;
    visibility: visible;
}

.scroll-top-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 30px rgba(147, 51, 234, 0.4);
}

.scroll-top-btn svg {
    width: 24px;
    height: 24px;
}

/* Home Button */
.home-btn {
    position: fixed;
    bottom: 30px;
    left: 30px;
    width: 50px;
    height: 50px;
    background: var(--secondary-gradient);
    border: none;
    border-radius: 50%;
    color: white;
    cursor: pointer;
    box-shadow: 0 4px 20px var(--shadow);
    transition: all var(--transition-speed);
    z-index: 999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.home-btn:hover {
    transform: translateY(-5px);
    box-shadow: 0 6px 30px rgba(245, 158, 11, 0.4);
}

.home-btn svg {
    width: 24px;
    height: 24px;
}

/* Enhanced Floating Elements */
.angel {
    position: absolute;
    font-size: 40px;
    opacity: 0.6;
    pointer-events: none;
    animation: float 20s infinite ease-in-out;
}

.angel-1 {
    left: 10%;
    top: 15%;
    animation-delay: 0s;
}

.angel-2 {
    right: 15%;
    top: 40%;
    animation-delay: 5s;
}

.praying {
    position: absolute;
    font-size: 35px;
    opacity: 0.5;
    pointer-events: none;
    animation: float 18s infinite ease-in-out;
}

.praying-1 {
    left: 25%;
    top: 60%;
    animation-delay: 3s;
}

.bible {
    position: absolute;
    font-size: 35px;
    opacity: 0.5;
    pointer-events: none;
    animation: float 22s infinite ease-in-out;
}

.bible-1 {
    right: 20%;
    top: 70%;
    animation-delay: 7s;
}

.cross-3 {
    position: absolute;
    left: 50%;
    top: 5%;
    font-size: 30px;
    opacity: 0.4;
    pointer-events: none;
    animation: float 16s infinite ease-in-out;
}

.star-3 {
    position: absolute;
    right: 10%;
    top: 85%;
    font-size: 25px;
    opacity: 0.5;
    pointer-events: none;
    animation: float 19s infinite ease-in-out;
}

/* Toast Notifications */
.toast-container {
    position: fixed;
    top: 80px;
    right: 20px;
    z-index: 10000;
    display: flex;
    flex-direction: column;
    gap: 10px;
    pointer-events: none;
}

.toast {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: 12px;
    padding: 16px 20px;
    min-width: 300px;
    max-width: 400px;
    box-shadow: 0 8px 32px var(--shadow);
    animation: slideInRight 0.3s ease-out;
    pointer-events: auto;
    display: flex;
    align-items: center;
    gap: 12px;
}

.toast.success {
    border-left: 4px solid #10b981;
}

.toast.error {
    border-left: 4px solid #ef4444;
}

.toast.info {
    border-left: 4px solid #3b82f6;
}

.toast.warning {
    border-left: 4px solid #f59e0b;
}

.toast-icon {
    font-size: 24px;
    flex-shrink: 0;
}

.toast-content {
    flex: 1;
}

.toast-title {
    font-weight: 600;
    margin-bottom: 4px;
}

.toast-message {
    font-size: 14px;
    opacity: 0.9;
}

@keyframes slideInRight {
    from {
        transform: translateX(100%);
        opacity: 0;
    }
    to {
        transform: translateX(0);
        opacity: 1;
    }
}

/* Modal Container */
.modal-container {
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.7);
    backdrop-filter: blur(5px);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.modal-container.hidden {
    display: none;
}

.modal-content {
    background: var(--card-bg);
    backdrop-filter: blur(20px);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius-lg);
    max-width: 800px;
    max-height: 90vh;
    width: 100%;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: modalFadeIn 0.3s ease-out;
}

@keyframes modalFadeIn {
    from {
        transform: scale(0.9);
        opacity: 0;
    }
    to {
        transform: scale(1);
        opacity: 1;
    }
}

/* Fasting Tracker Styles */
.fasting-calendar {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 10px;
    margin: 20px 0;
}

.calendar-day {
    aspect-ratio: 1;
    background: var(--card-bg);
    border: 2px solid var(--card-border);
    border-radius: 12px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all var(--transition-speed);
    position: relative;
}

.calendar-day:hover {
    transform: translateY(-2px);
    border-color: var(--primary);
    box-shadow: 0 4px 12px var(--shadow);
}

.calendar-day.fasting {
    background: var(--primary-gradient);
    border-color: #9333ea;
}

.calendar-day.today {
    border-color: #f59e0b;
    border-width: 3px;
}

.day-number {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 4px;
}

.fast-indicator {
    font-size: 20px;
    position: absolute;
    bottom: 5px;
}

.fasting-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.stat-card {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 24px;
    text-align: center;
}

.stat-value {
    font-size: 36px;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    margin: 10px 0;
}

.stat-label {
    font-size: 14px;
    opacity: 0.7;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Voice/Video Recording Styles */
.recording-controls {
    display: flex;
    gap: 15px;
    align-items: center;
    justify-content: center;
    padding: 20px;
    background: var(--card-bg);
    border-radius: var(--border-radius);
    margin: 20px 0;
}

.record-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all var(--transition-speed);
    box-shadow: 0 4px 12px var(--shadow);
}

.record-btn.recording {
    background: #ef4444;
    animation: pulse 1.5s infinite;
}

.record-btn:not(.recording) {
    background: var(--primary-gradient);
}

@keyframes pulse {
    0%, 100% {
        transform: scale(1);
        box-shadow: 0 4px 12px var(--shadow);
    }
    50% {
        transform: scale(1.1);
        box-shadow: 0 6px 20px rgba(239, 68, 68, 0.5);
    }
}

.recording-timer {
    font-size: 24px;
    font-weight: 600;
    font-variant-numeric: tabular-nums;
    color: #ef4444;
}

.media-preview {
    margin: 20px 0;
    border-radius: var(--border-radius);
    overflow: hidden;
}

.media-preview video,
.media-preview audio {
    width: 100%;
    max-height: 400px;
}

/* Dream Sketching Canvas */
.sketch-container {
    background: white;
    border-radius: var(--border-radius);
    padding: 20px;
    margin: 20px 0;
}

.sketch-canvas {
    border: 2px solid #e5e7eb;
    border-radius: 8px;
    cursor: crosshair;
    display: block;
    margin: 0 auto;
    max-width: 100%;
    touch-action: none;
}

.canvas-tools {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    align-items: center;
    margin: 20px 0;
    padding: 15px;
    background: #f3f4f6;
    border-radius: 8px;
}

.color-palette {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.color-btn {
    width: 36px;
    height: 36px;
    border: 3px solid #e5e7eb;
    border-radius: 50%;
    cursor: pointer;
    transition: transform 0.2s;
}

.color-btn.active {
    border-color: #1f2937;
    transform: scale(1.2);
}

.color-btn:hover {
    transform: scale(1.15);
}

.brush-sizes {
    display: flex;
    gap: 10px;
    align-items: center;
}

.brush-size-btn {
    width: 40px;
    height: 40px;
    border: 2px solid #e5e7eb;
    border-radius: 50%;
    background: white;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s;
}

.brush-size-btn.active {
    border-color: #9333ea;
    background: #f3e8ff;
}

.brush-size-indicator {
    background: #1f2937;
    border-radius: 50%;
}

/* Anointing Level Tracker */
.anointing-meter {
    position: relative;
    width: 100%;
    max-width: 400px;
    height: 200px;
    margin: 30px auto;
}

.meter-arc {
    width: 100%;
    height: 100%;
}

.meter-value {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -20%);
    text-align: center;
}

.meter-number {
    font-size: 48px;
    font-weight: 700;
    background: var(--primary-gradient);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.meter-label {
    font-size: 14px;
    opacity: 0.7;
    margin-top: 5px;
}

.level-indicators {
    display: flex;
    justify-content: space-between;
    margin-top: 10px;
    padding: 0 20px;
}

.level-indicator {
    font-size: 12px;
    opacity: 0.6;
}

/* Spiritual Season Detector */
.season-quiz {
    max-width: 600px;
    margin: 0 auto;
}

.quiz-question {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 24px;
    margin: 20px 0;
}

.question-text {
    font-size: 18px;
    font-weight: 600;
    margin-bottom: 20px;
}

.quiz-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.quiz-option {
    background: transparent;
    border: 2px solid var(--card-border);
    border-radius: 12px;
    padding: 16px 20px;
    cursor: pointer;
    transition: all var(--transition-speed);
    text-align: left;
}

.quiz-option:hover {
    border-color: #9333ea;
    background: rgba(147, 51, 234, 0.1);
}

.quiz-option.selected {
    border-color: #9333ea;
    background: var(--primary-gradient);
    color: white;
}

.season-result {
    background: var(--primary-gradient);
    border-radius: var(--border-radius-lg);
    padding: 40px;
    text-align: center;
    color: white;
    margin: 30px 0;
}

.season-icon {
    font-size: 80px;
    margin-bottom: 20px;
}

.season-name {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 15px;
}

.season-description {
    font-size: 16px;
    opacity: 0.9;
    line-height: 1.6;
}

/* Community Feed */
.community-feed {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.feed-post {
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 24px;
    transition: all var(--transition-speed);
}

.feed-post:hover {
    transform: translateY(-2px);
    box-shadow: 0 8px 24px var(--shadow);
}

.post-header {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 16px;
}

.post-avatar {
    width: 48px;
    height: 48px;
    border-radius: 50%;
    background: var(--primary-gradient);
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
}

.post-author {
    flex: 1;
}

.author-name {
    font-weight: 600;
    margin-bottom: 4px;
}

.post-date {
    font-size: 12px;
    opacity: 0.6;
}

.post-content {
    margin: 16px 0;
    line-height: 1.6;
}

.post-actions {
    display: flex;
    gap: 20px;
    padding-top: 16px;
    border-top: 1px solid var(--card-border);
}

.action-btn {
    background: none;
    border: none;
    color: var(--text-secondary);
    cursor: pointer;
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    transition: all var(--transition-speed);
}

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

.action-btn.liked {
    color: #ef4444;
}

/* Achievement Badges */
.badges-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
    gap: 20px;
    margin: 30px 0;
}

.badge {
    background: var(--card-bg);
    border: 2px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 20px;
    text-align: center;
    transition: all var(--transition-speed);
}

.badge.unlocked {
    border-color: #10b981;
    box-shadow: 0 4px 12px rgba(16, 185, 129, 0.3);
}

.badge.locked {
    opacity: 0.5;
    filter: grayscale(100%);
}

.badge:hover {
    transform: translateY(-5px);
}

.badge-icon {
    font-size: 48px;
    margin-bottom: 12px;
}

.badge-name {
    font-weight: 600;
    font-size: 14px;
    margin-bottom: 4px;
}

.badge-description {
    font-size: 12px;
    opacity: 0.7;
}

/* Progress Bars */
.progress-bar {
    width: 100%;
    height: 12px;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 6px;
    overflow: hidden;
    position: relative;
}

.progress-fill {
    height: 100%;
    background: var(--primary-gradient);
    transition: width 0.5s ease-out;
    position: relative;
    overflow: hidden;
}

.progress-fill::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    bottom: 0;
    right: 0;
    background: linear-gradient(
        90deg,
        transparent,
        rgba(255, 255, 255, 0.3),
        transparent
    );
    animation: shimmer 2s infinite;
}

@keyframes shimmer {
    0% {
        transform: translateX(-100%);
    }
    100% {
        transform: translateX(100%);
    }
}

/* Chart Container */
.chart-container {
    position: relative;
    width: 100%;
    height: 400px;
    margin: 30px 0;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 20px;
}

/* Timeline Visualization */
.timeline {
    position: relative;
    padding: 40px 0;
}

.timeline-line {
    position: absolute;
    left: 50%;
    top: 0;
    bottom: 0;
    width: 2px;
    background: var(--card-border);
    transform: translateX(-50%);
}

.timeline-item {
    display: flex;
    align-items: center;
    margin: 30px 0;
    position: relative;
}

.timeline-item:nth-child(odd) {
    flex-direction: row;
}

.timeline-item:nth-child(even) {
    flex-direction: row-reverse;
}

.timeline-content {
    flex: 1;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: var(--border-radius);
    padding: 20px;
    margin: 0 30px;
}

.timeline-dot {
    width: 20px;
    height: 20px;
    background: var(--primary-gradient);
    border-radius: 50%;
    border: 4px solid var(--bg-color);
    z-index: 1;
}

/* Pattern Heatmap */
.heatmap-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(60px, 1fr));
    gap: 8px;
    margin: 20px 0;
}

.heatmap-cell {
    aspect-ratio: 1;
    background: var(--card-bg);
    border: 1px solid var(--card-border);
    border-radius: 8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    transition: all var(--transition-speed);
    cursor: pointer;
}

.heatmap-cell:hover {
    transform: scale(1.1);
    z-index: 1;
}

.heatmap-cell.intensity-1 {
    background: rgba(147, 51, 234, 0.2);
}

.heatmap-cell.intensity-2 {
    background: rgba(147, 51, 234, 0.4);
}

.heatmap-cell.intensity-3 {
    background: rgba(147, 51, 234, 0.6);
}

.heatmap-cell.intensity-4 {
    background: rgba(147, 51, 234, 0.8);
}

.heatmap-cell.intensity-5 {
    background: rgba(147, 51, 234, 1);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
    .scroll-top-btn,
    .home-btn {
        width: 45px;
        height: 45px;
        bottom: 20px;
    }
    
    .scroll-top-btn {
        right: 20px;
    }
    
    .home-btn {
        left: 20px;
    }
    
    .fasting-calendar {
        grid-template-columns: repeat(7, 1fr);
        gap: 5px;
    }
    
    .calendar-day {
        font-size: 14px;
    }
    
    .toast {
        min-width: 280px;
        max-width: calc(100vw - 40px);
    }
    
    .badges-grid {
        grid-template-columns: repeat(auto-fill, minmax(100px, 1fr));
        gap: 15px;
    }
    
    .chart-container {
        height: 300px;
    }
}

/* High Contrast Mode */
body.high-contrast {
    --card-bg: #000000;
    --card-border: #ffffff;
    --text-color: #ffffff;
    --bg-color: #000000;
}

body.high-contrast .btn {
    border: 2px solid #ffffff;
}

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

/* Print Styles */
@media print {
    .scroll-top-btn,
    .home-btn,
    .nav-tabs,
    .settings-panel,
    .floating-elements,
    .animated-background {
        display: none !important;
    }
    
    .container {
        max-width: 100%;
    }
    
    .card {
        page-break-inside: avoid;
    }
}
