﻿:root {
    --chat-bg: #f8f9fa;
    --border-color: #dee2e6;
    --card-shadow: 0 0.5rem 1rem rgba(0, 0, 0, 0.1);
    --bubble-shadow: 0 2px 4px rgba(0, 0, 0, 0.075);
}
/* Selected card visual state */
.persona-tile.selected {
    border-top-color: #9c66ff !important;
    box-shadow: 0 6px 18px rgba(156, 102, 255, 0.35) !important;
    background: linear-gradient(180deg, #f9f6ff 0%, #ffffff 100%) !important;
}

/* Hover state */
.persona-tile:hover {
    cursor: pointer;
}

/* Smooth fade + lift for buttons inside selected card */
.persona-tile.selected .proceed-inline {
    transition: opacity .25s ease, transform .25s ease !important;
}

/* Fade-in when card is selected */
.persona-tile.selected .proceed-inline,
.author-style-card.selected .proceed-inline {
    opacity: 1;
    transform: translateY(0);
}

/* Button hover polish */
.proceed-inline button {
    transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
}

    .proceed-inline button:hover {
        transform: translateY(-1px);
        box-shadow: 0 4px 10px rgba(0, 0, 0, 0.08);
    }

.persona-tile {
    width: 90px;
    height: 90px;
    border-radius: 14px;
    transition: all 0.2s ease;
}

    .persona-tile:hover {
        cursor: pointer;
        transform: translateY(-2px);
        box-shadow: 0 3px 10px rgba(0,0,0,0.1);
    }

    .persona-tile.active {
        border-width: 2px !important;
        box-shadow: 0 0 0.5rem rgba(13,110,253,0.25);
    }


    .persona-tile.selected {
        border-top-color: #9c66ff !important;
        box-shadow: 0 6px 18px rgba(156,102,255,0.35) !important;
        background: linear-gradient(180deg, #f9f6ff 0%, #ffffff 100%) !important;
    }

   /* .persona-tile.selected {
        transform: scale(1.04);
        border: 2px solid #9c66ff !important;
        box-shadow: 0 8px 20px rgba(156,102,255,0.25);
    }*/



.card:hover img {
    transform: scale(1.02);
    transition: transform 0.4s ease;
}
.author-style-card {
    position: relative;
    transition: all 0.2s ease;
}

.proceed-inline {
    transition: opacity 0.25s ease;
}

.author-style-card.selected .proceed-inline {
    opacity: 1;
}
.persona-style-card {
    position: relative;
    transition: all 0.2s ease;
}

.proceed-inline {
    transition: opacity 0.25s ease;
}

.persona-style-card.selected .proceed-inline {
    opacity: 1;
}

.character-style-card {
    position: relative;
    transition: all 0.2s ease;
}

.proceed-inline {
    transition: opacity 0.25s ease;
}

.character-style-card.selected .proceed-inline {
    opacity: 1;
}

.co-author-container {
    max-width: 800px;
    margin: auto;
}

.chat-card {
    border: none;
    border-radius: 0.75rem;
    box-shadow: var(--card-shadow);
    overflow: hidden;
}

.chat-header {
    background-color: #0d6efd;
    color: white;
    padding: 1rem 1.5rem;
    text-align: center;
}

    .chat-header h2 {
        font-size: 1.5rem;
        margin-bottom: 0.25rem;
    }

    .chat-header p {
        opacity: 0.9;
    }

.chat-messages {
    background-color: var(--chat-bg);
    padding: 1.5rem;
    max-height: 60vh;
    overflow-y: auto;
    display: flex;
    flex-direction: column;
  /*  gap: 1rem;*/
}

.message-bubble {
    width: fit-content;
    max-width: 80%;
    padding: 0.75rem 1.25rem;
    border-radius: 0.75rem;
    word-wrap: break-word;
    box-shadow: var(--bubble-shadow);
    position: relative;
}

    .message-bubble .sender-info {
        font-weight: bold;
        font-size: 0.8rem;
       /* margin-bottom: 0.25rem;*/
        opacity: 0.8;
    }

    .message-bubble .timestamp {
        font-size: 0.75rem;
        opacity: 0.6;
        margin-left: 0.5rem;
    }

.human-message {
    align-self: flex-end;
    background-color: #fff;
    border: 1px solid #0d6efd;
    color: #0d6efd;
}

.ai-message {
    align-self: flex-start;
    background-color: #f1f3f5;
}

.chat-footer {
    padding: 1rem 1.5rem;
    background-color: #fff;
    border-top: 1px solid var(--border-color);
}

.chat-input-group {
    display: flex;
    gap: 0.75rem;
    align-items: flex-end;
}

.auto-expand-textarea {
    resize: none;
    overflow-y: hidden;
    min-height: 48px;
    max-height: 200px;
    line-height: 1.5;
}

.form-control-setup {
    min-height: 52px;
}


.character-image {
    height: 220px;
    width: 100%;
    object-fit: cover;
    object-position: center;
    transition: transform 0.3s ease, filter 0.3s ease;
}

    .character-image.portrait {
        object-fit: contain;
        background-color: #f8f9fa;
    }

    .character-image:hover {
        transform: scale(1.03);
        filter: brightness(1.05);
    }


.timeline-complete .step-spinner {
    display: none !important;
}

.timeline-complete .fw-bold {
    color: #198754 !important; /* success green */
}

.timeline-complete .completed-marker::before {
    content: "✔ ";
    color: #198754;
    font-weight: bold;
}


/* Pills */
.step-pill {
    flex: 1;
    text-align: center;
    padding: 10px 0;
    border-bottom: 3px solid #ddd;
    color: #999;
    font-size: 0.9rem;
    font-weight: 600;
}

    .step-pill.active {
        color: #0d6efd;
        border-color: #0d6efd;
    }

    .step-pill.complete {
        color: #198754;
        border-color: #198754;
    }

/* Flash card */
.tracker-card {
    background: #fff;
    border-radius: 8px;
    padding: 25px;
    box-shadow: 0 4px 14px rgba(0,0,0,0.1);
    animation: fadeIn 0.25s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
        transform: translateY(10px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}


/*Claude Styles*/
/*Claude Styles*/
/*Claude Styles*/
/*Claude Styles*/




/* ==========================================
   OUTLINE TRACKER - ENHANCED STYLES
   ==========================================
   - Stops flashing on completion
   - Clickable pills in review mode
   - Current step display (single, not accumulated)
   - Step review panel
   ========================================== */

/* Base tracker step */
.tracker-step {
    position: relative;
    z-index: 1;
    transition: all 0.3s ease;
}

    .tracker-step .bubble {
        width: 36px;
        height: 36px;
        border-radius: 50%;
        background: #e9ecef;
        border: 2px solid #dee2e6;
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: 600;
        font-size: 0.85rem;
        color: #6c757d;
        transition: all 0.3s ease;
    }

    .tracker-step .label {
        font-size: 0.7rem;
        color: #6c757d;
        margin-top: 4px;
        text-align: center;
        white-space: nowrap;
    }

    /* Active state - PULSING animation */
    .tracker-step.active .bubble {
        background: #0d6efd;
        border-color: #0d6efd;
        color: white;
        box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.2);
        animation: pulse 1.5s infinite;
    }

    .tracker-step.active .label {
        color: #0d6efd;
        font-weight: 600;
    }

@keyframes pulse {
    0%, 100% {
        box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.2);
    }

    50% {
        box-shadow: 0 0 0 8px rgba(13, 110, 253, 0.1);
    }
}

/* Completed state (during progress) */
.tracker-step.completed .bubble {
    background: #198754;
    border-color: #198754;
    color: white;
}

.tracker-step.completed .label {
    color: #198754;
}

/* ==========================================
   DONE STATE - NO ANIMATION
   This is the key fix for the flashing issue
   ========================================== */
.tracker-step.done .bubble {
    background: #198754;
    border-color: #198754;
    color: white;
    animation: none !important;
    box-shadow: none !important;
}

.tracker-step.done .label {
    color: #198754;
}

/* Progress bar complete state */
.tracker-bar-fill.complete {
    background: linear-gradient(90deg, #198754, #20c997) !important;
    animation: none !important;
}

/* ==========================================
   REVIEW MODE - Clickable pills
   ========================================== */
.tracker-container.review-mode .tracker-step.clickable {
    cursor: pointer;
}

    .tracker-container.review-mode .tracker-step.clickable:hover .bubble {
        transform: scale(1.1);
        box-shadow: 0 2px 8px rgba(0,0,0,0.15);
    }

    .tracker-container.review-mode .tracker-step.clickable:hover .label {
        color: #0d6efd;
    }

/* Currently reviewing state */
.tracker-step.reviewing .bubble {
    background: #0d6efd !important;
    border-color: #0d6efd !important;
    color: white !important;
    transform: scale(1.1);
    box-shadow: 0 0 0 4px rgba(13, 110, 253, 0.25);
    animation: none !important;
}

.tracker-step.reviewing .label {
    color: #0d6efd !important;
    font-weight: 600;
}

/* Review mode hint */
#outlineTracker.review-mode::after {
    content: "Click a step to review details";
    display: block;
    text-align: center;
    font-size: 0.75rem;
    color: #6c757d;
    margin-top: 12px;
    font-style: italic;
}

/* ==========================================
   CURRENT STEP DISPLAY
   (replaces the accumulated mess)
   ========================================== */
#outlineCurrentStep {
    margin-top: 1rem;
}

.current-step-card {
    background: linear-gradient(135deg, #f8f9fa 0%, #fff 100%);
    border: 1px solid #e9ecef;
    border-radius: 8px;
    padding: 1rem;
    box-shadow: 0 2px 4px rgba(0,0,0,0.04);
}

    /* Simplify the spinner display in current step */
    .current-step-card .spinner-border {
        width: 1.5rem;
        height: 1.5rem;
    }

    .current-step-card .text-center {
        padding: 0.5rem 0 !important;
    }

/* ==========================================
   STEP REVIEW PANEL
   ========================================== */
#outlineStepReview {
    margin-top: 1rem;
}

.step-review-card {
    background: #fff;
    border: 1px solid #dee2e6;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.06);
}

.step-review-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 0.75rem 1rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
}

.step-badge {
    background: rgba(255,255,255,0.2);
    padding: 0.25rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 600;
}

.step-label {
    font-weight: 600;
}

.step-review-content {
    padding: 1rem;
    max-height: 300px;
    overflow-y: auto;
}

    /* Clean up review content styling */
    .step-review-content .spinner-border {
        display: none; /* Hide old spinners in review */
    }

    .step-review-content h5 {
        font-size: 1rem;
        margin-bottom: 0.5rem;
    }

    .step-review-content p {
        margin-bottom: 0.25rem;
    }

/* ==========================================
   TRACKER BAR STYLING
   ========================================== */
.tracker-bar-bg {
    position: absolute;
    top: 18px;
    left: 10%;
    right: 10%;
    height: 4px;
    background: #e9ecef;
    border-radius: 2px;
    z-index: 0;
}

.tracker-bar-fill {
    height: 100%;
    background: linear-gradient(90deg, #198754, #0d6efd);
    border-radius: 2px;
    transition: width 0.5s ease;
    width: 0%;
}

.tracker-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 1;
}

.tracker-container {
    position: relative;
    padding: 0 10px;
}
