﻿:root {
    --primary-blue: #2c5aa0;
    --accent-gold: #f4b942;
    --light-bg: #f8f9fa;
    --card-hover: #e8f4f8;
}

body {
    background-color: var(--light-bg);
}


.story-accumulator {
    margin: 20px 0;
    padding: 15px;
    background: #f5f5f5;
    border-radius: 8px;
    max-height: 400px;
    overflow-y: auto;
}

.story-segment {
    padding: 10px;
    margin-bottom: 10px;
    background: white;
    border-left: 3px solid #4a90e2;
    border-radius: 4px;
}

    .story-segment:last-child {
        margin-bottom: 0;
        border-left-color: #50c878; /* Highlight the newest one */
    }

.page-header {
    background: linear-gradient(135deg, var(--primary-blue) 0%, #1e3a6f 100%);
    color: white;
    padding: 2rem 0;
    margin-bottom: 2rem;
}

.nav-tabs .dropdown-toggle {
    font-weight: 600;
    letter-spacing: .2px;
}

.section-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
    padding: 2rem;
    margin-bottom: 2rem;
}

.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    color: var(--primary-blue);
    margin-bottom: 1.5rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.author-style-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    height: 100%;
    position: relative;
}

    .author-style-card:hover {
        border-color: var(--primary-blue);
        background: var(--card-hover);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(44, 90, 160, 0.15);
    }

    .author-style-card.selected {
        border-color: var(--accent-gold);
        background: #fffbf0;
        box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.2);
    }

    .author-style-card.no-preference {
        border: 2px dashed #999;
        background: #fefefe;
    }

        .author-style-card.no-preference.selected {
            border-color: var(--accent-gold);
            background: #fffbf0;
            box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.15);
        }

.styles-collapsed .author-style-card:nth-child(n+9) {
    display: none;
}

.author-style-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    display: block;
}

.author-style-name {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: #333;
}

.author-style-description {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}


/*persona*/
    .persona-style-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    height: 100%;
    position: relative;
}

    .persona-style-card:hover {
        border-color: var(--primary-blue);
        background: var(--card-hover);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(44, 90, 160, 0.15);
    }

    .persona-style-card.selected {
        border-color: var(--accent-gold);
        background: #fffbf0;
        box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.2);
    }

    .persona-style-card.no-preference {
        border: 2px dashed #999;
        background: #fefefe;
    }

        .persona-style-card.no-preference.selected {
            border-color: var(--accent-gold);
            background: #fffbf0;
            box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.15);
        }

.styles-collapsed .persona-style-card:nth-child(n+9) {
    display: none;
}

.persona-style-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    display: block;
}

.persona-style-name {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: #333;
}

.persona-style-description {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}




/*character*/
.character-style-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    padding: 1rem;
    cursor: pointer;
    transition: all 0.3s ease;
    background: white;
    height: 100%;
    position: relative;
}

    .character-style-card:hover {
        border-color: var(--primary-blue);
        background: var(--card-hover);
        transform: translateY(-2px);
        box-shadow: 0 4px 12px rgba(44, 90, 160, 0.15);
    }

    .character-style-card.selected {
        border-color: var(--accent-gold);
        background: #fffbf0;
        box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.2);
    }

    .character-style-card.no-preference {
        border: 2px dashed #999;
        background: #fefefe;
    }

        .character-style-card.no-preference.selected {
            border-color: var(--accent-gold);
            background: #fffbf0;
            box-shadow: 0 0 0 3px rgba(244, 185, 66, 0.15);
        }

.styles-collapsed .character-style-card:nth-child(n+9) {
    display: none;
}

.character-style-icon {
    font-size: 2.5rem;
    margin-bottom: 0.5rem;
    display: block;
}

.character-style-name {
    font-weight: 600;
    font-size: 1rem;
    margin-bottom: 0.25rem;
    color: #333;
}

.character-style-description {
    font-size: 0.85rem;
    color: #666;
    line-height: 1.4;
}










.or-divider {
    position: relative;
    text-align: center;
    margin: 2.5rem 0;
    display: none; /* Hidden in side-by-side layout */
}

    .or-divider::before {
        content: '';
        position: absolute;
        top: 50%;
        left: 0;
        right: 0;
        height: 2px;
        background: linear-gradient(to right, transparent, #ddd 20%, #ddd 80%, transparent);
    }

.or-divider-text {
    position: relative;
    display: inline-block;
    background: var(--light-bg);
    padding: 0.5rem 2rem;
    font-size: 1.25rem;
    font-weight: 600;
    color: #666;
    border-radius: 25px;
    border: 2px solid #ddd;
}




.custom-author-section {
    /* No longer needs opacity/pointer-events changes */
}

    .custom-author-section.active {
        /* Not needed in side-by-side */
    }

        .custom-author-section.active .section-card {
            /* Not needed in side-by-side */
        }

#authorStylesContainer {
    max-height: 850px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.5rem;
}

    #authorStylesContainer.styles-collapsed {
        max-height: none;
        overflow: visible;
    }

        #authorStylesContainer.styles-collapsed .author-style-card:nth-child(n+9) {
            display: none;
        }

.available-author-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: white;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

    .available-author-card:hover {
        border-color: var(--primary-blue);
        box-shadow: 0 2px 8px rgba(44, 90, 160, 0.1);
    }

    .available-author-card.selected {
        border-color: var(--primary-blue);
        background: #f0f7ff;
    }

.author-card-header {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

.author-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.author-card-info {
    flex: 1;
}

.author-card-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.author-card-meta {
    font-size: 0.85rem;
    color: #666;
}

.author-style-card .author-style-icon {
    font-size: 1.75rem;
    line-height: 1;
}

.custom-character-section {
    /* No longer needs opacity/pointer-events changes */
}

    .custom-character-section.active {
        /* Not needed in side-by-side */
    }

        .custom-character-section.active .section-card {
            /* Not needed in side-by-side */
        }

#characterStylesContainer {
    max-height: 850px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.5rem;
}

    #characterStylesContainer.styles-collapsed {
        max-height: none;
        overflow: visible;
    }

        #characterStylesContainer.styles-collapsed .character-style-card:nth-child(n+9) {
            display: none;
        }

.available-character-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: white;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

    .available-character-card:hover {
        border-color: var(--primary-blue);
        box-shadow: 0 2px 8px rgba(44, 90, 160, 0.1);
    }

    .available-character-card.selected {
        border-color: var(--primary-blue);
        background: #f0f7ff;
    }

.character-card-header {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

.character-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.character-card-info {
    flex: 1;
}

.character-card-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.character-card-meta {
    font-size: 0.85rem;
    color: #666;
}

.character-style-card .character-style-icon {
    font-size: 1.75rem;
    line-height: 1;
}

.custom-persona-section {
    /* No longer needs opacity/pointer-events changes */
}

    .custom-persona-section.active {
        /* Not needed in side-by-side */
    }

        .custom-persona-section.active .section-card {
            /* Not needed in side-by-side */
        }

#personaStylesContainer {
    max-height: 850px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 0.5rem;
}

    #personaStylesContainer.styles-collapsed {
        max-height: none;
        overflow: visible;
    }

        #personaStylesContainer.styles-collapsed .persona-style-card:nth-child(n+9) {
            display: none;
        }

.available-persona-card {
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    background: white;
    margin-bottom: 1rem;
    transition: all 0.2s ease;
}

    .available-persona-card:hover {
        border-color: var(--primary-blue);
        box-shadow: 0 2px 8px rgba(44, 90, 160, 0.1);
    }

    .available-persona-card.selected {
        border-color: var(--primary-blue);
        background: #f0f7ff;
    }

.persona-card-header {
    padding: 1rem 1.5rem;
    display: flex;
    align-items: center;
    gap: 1rem;
    cursor: pointer;
}

.persona-checkbox {
    width: 20px;
    height: 20px;
    cursor: pointer;
}

.persona-card-info {
    flex: 1;
}

.persona-card-name {
    font-weight: 600;
    font-size: 1.1rem;
    margin-bottom: 0.25rem;
}

.persona-card-meta {
    font-size: 0.85rem;
    color: #666;
}

.persona-style-card .persona-style-icon {
    font-size: 1.75rem;
    line-height: 1;
}














.badge-custom {
    font-size: 0.75rem;
    padding: 0.25rem 0.6rem;
    margin-right: 0.25rem;
}

.accordion-content {
    border-top: 1px solid #e0e0e0;
    padding: 1.5rem;
    background: #fafafa;
}

.stat-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1rem;
    margin-top: 1rem;
}

.stat-item {
    background: white;
    padding: 0.75rem;
    border-radius: 6px;
    border-left: 3px solid var(--primary-blue);
}

.stat-label {
    font-size: 0.75rem;
    color: #666;
    text-transform: uppercase;
    font-weight: 600;
    margin-bottom: 0.25rem;
}

.stat-value {
    font-size: 0.9rem;
    color: #333;
}

.action-buttons {
    display: flex;
    gap: 1rem;
    margin-top: 2rem;
}

.btn-primary-custom {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    padding: 0.75rem 2rem;
    font-weight: 600;
}

    .btn-primary-custom:hover {
        background: #1e3a6f;
        border-color: #1e3a6f;
    }

.btn-accent {
    background: var(--accent-gold);
    border-color: var(--accent-gold);
    color: #333;
    padding: 0.75rem 2rem;
    font-weight: 600;
}

    .btn-accent:hover {
        background: #e0a832;
        border-color: #e0a832;
        color: #333;
    }

.advanced-options {
    background: #f8f9fa;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 1.5rem;
    margin-top: 1rem;
}

.collapse-toggle {
    cursor: pointer;
    user-select: none;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--primary-blue);
}

    .collapse-toggle:hover {
        color: #1e3a6f;
    }

.icon-rotate {
    transition: transform 0.3s ease;
}

    .icon-rotate.expanded {
        transform: rotate(90deg);
    }

.no-authors-message {
    text-align: center;
    padding: 2rem;
    color: #666;
    font-style: italic;
}

/* label + select sweetening */
.form-label {
    font-weight: 600;
    letter-spacing: .2px;
}

.form-select {
    border-radius: .65rem;
    border-color: rgba(99,102,241,.35);
    box-shadow: inset 0 1px 2px rgba(0,0,0,.04);
}

.tracker-container {
    position: relative;
    margin-top: 10px;
}

.tracker-steps {
    display: flex;
    justify-content: space-between;
    position: relative;
    z-index: 2;
}

.tracker-step {
    text-align: center;
    width: 100%;
}

    .tracker-step .label {
        font-size: 0.75rem;
        margin-top: 6px;
        color: #6c757d;
    }

/* The bubbles */
.bubble {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    margin: 0 auto;
    font-size: 0.9rem;
    font-weight: 600;
    color: white;
    background: #adb5bd;
    display: flex;
    justify-content: center;
    align-items: center;
    transition: all 0.25s ease;
}

/* Active step (blue glow) */
.tracker-step.active .bubble {
    background: #0d6efd;
    box-shadow: 0 0 12px rgba(13,110,253,0.7);
    animation: pulse 1.5s infinite;
}

/* Completed step (green check) */
.tracker-step.completed .bubble {
    background: #28a745;
    box-shadow: none;
    animation: none;
}

/* Step labels when active or done */
.tracker-step.active .label,
.tracker-step.completed .label {
    font-weight: 600;
    color: #212529;
}

/* Connecting bar */
.tracker-bar-bg {
    position: absolute;
    top: 16px;
    left: 0;
    right: 0;
    height: 4px;
    background: #e9ecef;
    z-index: 1;
    border-radius: 20px;
}

.tracker-bar-fill {
    height: 4px;
    width: 0%;
    background: #0d6efd;
    transition: width 0.5s ease;
    border-radius: 20px;
}

/* Pulse animation */
@keyframes pulse {
    0% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.08);
    }

    100% {
        transform: scale(1);
    }
}

@keyframes pulse {
    0%,100% {
        opacity: .35;
        transform: translateY(0);
    }

    50% {
        opacity: 1;
        transform: translateY(-1px);
    }
}

.tracker-step.longrun.active .bubble {
    background: linear-gradient(90deg, #0d6efd, #4dabff, #0d6efd);
    background-size: 200%;
    animation: longrun 2s infinite;
}

@keyframes longrun {
    0% {
        background-position: 0%;
    }

    100% {
        background-position: 200%;
    }
}