/* ===================================
   Enhanced Modal Styles for ROLLIN
   Roadmap & About Modal Animations
   =================================== */

/* Roadmap Timeline Enhancements */
.roadmap-content {
    position: relative;
    padding: 0 0.5rem;
}

.roadmap-timeline {
    position: relative;
    padding-left: 2.5rem;
}

/* Vertical timeline line */
.roadmap-timeline::before {
    content: '';
    position: absolute;
    left: 1.25rem;
    top: 3rem;
    bottom: 3rem;
    width: 3px;
    background: linear-gradient(
        to bottom,
        var(--primary-color) 0%,
        var(--primary-color) 30%,
        rgba(37, 99, 235, 0.3) 100%
    );
    border-radius: 2px;
}

.roadmap-phase {
    position: relative;
    margin-bottom: 2rem;
    opacity: 0;
    transform: translateY(30px);
    transition: all 0.6s cubic-bezier(0.4, 0, 0.2, 1);
}

.roadmap-phase.visible {
    opacity: 1;
    transform: translateY(0);
}

/* Timeline dot */
.roadmap-phase::before {
    content: '';
    position: absolute;
    left: -2.5rem;
    top: 0.5rem;
    width: 1.5rem;
    height: 1.5rem;
    border-radius: 50%;
    background: var(--color-bg-primary);
    border: 3px solid var(--primary-color);
    z-index: 2;
    transition: all 0.3s ease;
}

.roadmap-phase.phase-current::before {
    background: var(--primary-color);
    box-shadow: 0 0 20px rgba(37, 99, 235, 0.6);
    animation: pulse-dot 2s ease-in-out infinite;
}

.roadmap-phase.phase-completed::before {
    background: var(--accent-color);
    border-color: var(--accent-color);
}

@keyframes pulse-dot {
    0%, 100% { transform: scale(1); box-shadow: 0 0 20px rgba(37, 99, 235, 0.6); }
    50% { transform: scale(1.1); box-shadow: 0 0 30px rgba(37, 99, 235, 0.8); }
}

/* Phase header with progress */
.phase-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 0.75rem;
    padding: 0.875rem 1rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    transition: all 0.3s ease;
}

.phase-header:hover {
    background: var(--glass-bg-hover);
    transform: translateX(5px);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
}

.phase-badge {
    padding: 0.4rem 0.8rem;
    border-radius: 20px;
    font-size: 0.75rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    white-space: nowrap;
}

.phase-badge.complete {
    background: rgba(16, 185, 129, 0.2);
    color: #10b981;
    border: 1px solid rgba(16, 185, 129, 0.3);
    cursor: pointer;
    position: relative;
}

.phase-badge.complete::after {
    content: 'Click for confetti! 🎉';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: rgba(0, 0, 0, 0.9);
    color: white;
    padding: 0.5rem 0.75rem;
    border-radius: 6px;
    font-size: 0.75rem;
    white-space: nowrap;
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.3s ease;
    margin-bottom: 0.5rem;
}

.phase-badge.complete:hover::after {
    opacity: 1;
}

.phase-badge.current {
    background: rgba(59, 130, 246, 0.2);
    color: #60a5fa;
    border: 1px solid rgba(59, 130, 246, 0.3);
    animation: badge-glow 2s ease-in-out infinite;
}

.phase-badge.upcoming {
    background: rgba(168, 85, 247, 0.2);
    color: #c084fc;
    border: 1px solid rgba(168, 85, 247, 0.3);
}

@keyframes badge-glow {
    0%, 100% { box-shadow: 0 0 10px rgba(59, 130, 246, 0.3); }
    50% { box-shadow: 0 0 20px rgba(59, 130, 246, 0.6); }
}

/* Progress Circle */
.phase-progress {
    width: 50px;
    height: 50px;
    position: relative;
    flex-shrink: 0;
}

.progress-ring {
    transform: rotate(-90deg);
}

.progress-ring-circle {
    transition: stroke-dashoffset 1s ease-out;
}

.progress-percent {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
}

/* Roadmap list items */
.roadmap-list {
    list-style: none;
    padding: 0 0 0 1rem;
    margin: 0;
}

.roadmap-list li {
    position: relative;
    padding: 0.75rem 0 0.75rem 2rem;
    margin-bottom: 0.5rem;
    color: var(--text-secondary);
    line-height: 1.6;
    transition: all 0.3s ease;
}

.roadmap-list li::before {
    content: '○';
    position: absolute;
    left: 0;
    color: var(--primary-color);
    font-size: 1.2rem;
    transition: all 0.3s ease;
}

.roadmap-list li.completed::before {
    content: '✓';
    color: var(--accent-color);
    font-weight: bold;
}

.roadmap-list li:hover {
    color: var(--text-primary);
    transform: translateX(5px);
}

.roadmap-list li:hover::before {
    transform: scale(1.3);
}

/* Animated Stats Counter */
.stat-number {
    font-size: 2.5rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--primary-color), var(--accent-color));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    display: inline-block;
}

/* About Section Cards */
.about-section {
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 12px;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    transition: all 0.3s ease;
    opacity: 0;
    transform: translateY(20px);
}

.about-section.visible {
    opacity: 1;
    transform: translateY(0);
}

.about-section:hover {
    background: var(--glass-bg-hover);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
    transform: translateY(-2px);
}

/* Tab Navigation for About */
.about-tabs {
    display: flex;
    gap: 0.5rem;
    margin-bottom: 2rem;
    border-bottom: 2px solid var(--glass-border);
    overflow-x: auto;
    padding-bottom: 0.5rem;
}

.about-tab {
    padding: 0.75rem 1.5rem;
    background: transparent;
    border: none;
    border-bottom: 3px solid transparent;
    color: var(--text-secondary);
    cursor: pointer;
    font-size: 0.95rem;
    font-weight: 500;
    transition: all 0.3s ease;
    white-space: nowrap;
}

.about-tab:hover {
    color: var(--text-primary);
    background: rgba(255, 255, 255, 0.05);
}

.about-tab.active {
    color: var(--primary-color);
    border-bottom-color: var(--primary-color);
    font-weight: 600;
}

.about-tab-content {
    display: none;
    animation: fadeIn 0.5s ease;
}

.about-tab-content.active {
    display: block;
}

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

/* Expandable Sections */
.expandable-section {
    margin-bottom: 1rem;
}

.expandable-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
}

.expandable-header:hover {
    background: var(--glass-bg-hover);
    transform: translateX(5px);
}

.expandable-icon {
    font-size: 1.5rem;
    transition: transform 0.3s ease;
}

.expandable-section.expanded .expandable-icon {
    transform: rotate(180deg);
}

.expandable-content {
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.5s cubic-bezier(0.4, 0, 0.2, 1);
}

.expandable-section.expanded .expandable-content {
    max-height: 2000px;
    padding: 1rem;
}

/* Stats Grid */
.stats-showcase {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 1rem;
    margin: 1.5rem 0;
}

.stat-card {
    text-align: center;
    padding: 1.5rem 1rem;
    background: var(--glass-bg);
    border: 1px solid var(--glass-border);
    border-radius: 10px;
    backdrop-filter: var(--glass-blur);
    -webkit-backdrop-filter: var(--glass-blur);
    transition: all 0.3s ease;
}

.stat-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 32px rgba(0, 0, 0, 0.3);
}

.stat-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
}

.stat-label {
    font-size: 0.85rem;
    color: var(--text-secondary);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 0.5rem;
}

/* Scroll Progress Indicator */
.modal-scroll-progress {
    position: absolute;
    top: 0;
    left: 0;
    height: 3px;
    background: linear-gradient(90deg, var(--primary-color), var(--accent-color));
    width: 0%;
    transition: width 0.1s ease;
    z-index: 1000;
    border-radius: 0 2px 2px 0;
}

/* Confetti Animation */
@keyframes confetti-fall {
    0% {
        transform: translateY(-100vh) rotate(0deg);
        opacity: 1;
    }
    100% {
        transform: translateY(100vh) rotate(720deg);
        opacity: 0;
    }
}

.confetti {
    position: fixed;
    width: 10px;
    height: 10px;
    background: var(--accent-color);
    animation: confetti-fall 3s linear forwards;
    z-index: 10000;
    pointer-events: none;
}

/* Responsive adjustments */
@media (max-width: 768px) {
    .roadmap-timeline {
        padding-left: 2rem;
    }

    .roadmap-timeline::before {
        left: 0.75rem;
    }

    .roadmap-phase::before {
        left: -1.75rem;
        width: 1rem;
        height: 1rem;
    }

    .phase-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .phase-progress {
        align-self: center;
    }

    .stat-number {
        font-size: 2rem;
    }

    .about-tabs {
        gap: 0.25rem;
    }

    .about-tab {
        padding: 0.5rem 1rem;
        font-size: 0.85rem;
    }
}
