
/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

:root {
    --primary-color: #2563eb;
    --primary-hover: #1e40af;
    --secondary-color: #64748b;
    --danger-color: #dc2626;
    --danger-hover: #b91c1c;
    --success-color: #16a34a;
    --success-bg: #dcfce7;
    --error-color: #dc2626;
    --error-bg: #fee2e2;
    --text-color: #1e293b;
    --text-light: #64748b;
    --border-color: #e2e8f0;
    --bg-color: #f8fafc;
    --white: #ffffff;
    --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px -1px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -2px rgba(0, 0, 0, 0.1);
}

body {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    font-size: 16px;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--bg-color);
}

/* Container */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1rem;
}

/* Navigation */
.navbar {
    background-color: var(--white);
    border-bottom: 1px solid var(--border-color);
    padding: 1rem 0;
    box-shadow: var(--shadow);
}

.navbar .container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.navbar-brand a {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
}

.navbar-menu {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.navbar-item {
    color: var(--text-color);
    text-decoration: none;
    padding: 0.5rem 1rem;
    border-radius: 0.375rem;
    transition: background-color 0.2s;
}

.navbar-item:hover {
    background-color: var(--bg-color);
}

.navbar-item.btn-link {
    background: none;
    border: none;
    cursor: pointer;
    font-size: 1rem;
    font-family: inherit;
}

/* Main Content */
.main-content {
    min-height: calc(100vh - 200px);
    padding: 2rem 0;
}

/* Breadcrumb */
.breadcrumb {
    margin-bottom: 1.5rem;
    padding: 0.75rem 0;
    font-size: 0.875rem;
    color: var(--text-light);
}

.breadcrumb a {
    color: var(--primary-color);
    text-decoration: none;
}

.breadcrumb a:hover {
    text-decoration: underline;
}

.breadcrumb .separator {
    margin: 0 0.5rem;
}

.breadcrumb .current {
    color: var(--text-color);
}

/* Page Header */
.page-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    flex-wrap: wrap;
    gap: 1rem;
}

.page-header h1 {
    font-size: 2rem;
    font-weight: 700;
    color: var(--text-color);
}

.page-actions {
    display: flex;
    gap: 0.5rem;
}

/* Buttons */
.btn {
    display: inline-block;
    padding: 0.625rem 1.25rem;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: center;
    text-decoration: none;
    border: 1px solid transparent;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s;
    background-color: var(--white);
    color: var(--text-color);
    border-color: var(--border-color);
}

.btn:hover {
    background-color: var(--bg-color);
}

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

.btn-primary:hover {
    background-color: var(--primary-hover);
    border-color: var(--primary-hover);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
    border-color: var(--secondary-color);
}

.btn-secondary:hover {
    background-color: #475569;
}

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

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

.btn-sm {
    padding: 0.375rem 0.75rem;
    font-size: 0.75rem;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Cards */
.card {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    box-shadow: var(--shadow);
    margin-bottom: 1.5rem;
}

.card-header {
    padding: 1rem 1.5rem;
    border-bottom: 1px solid var(--border-color);
}

.card-header h2 {
    font-size: 1.25rem;
    font-weight: 600;
}

.card-body {
    padding: 1.5rem;
}

/* Tables */
.table-container {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.table {
    width: 100%;
    border-collapse: collapse;
}

.table th {
    background-color: var(--bg-color);
    padding: 0.75rem 1rem;
    text-align: left;
    font-weight: 600;
    font-size: 0.875rem;
    color: var(--text-light);
    border-bottom: 1px solid var(--border-color);
}

.table td {
    padding: 1rem;
    border-bottom: 1px solid var(--border-color);
}

.table tbody tr:last-child td {
    border-bottom: none;
}

.table tbody tr:hover {
    background-color: var(--bg-color);
}

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

.link-bold {
    font-weight: 600;
    color: var(--primary-color);
    text-decoration: none;
}

.link-bold:hover {
    text-decoration: underline;
}

/* Forms */
.form-container {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 2rem;
    box-shadow: var(--shadow);
}

.form {
    max-width: 600px;
}

.form-group {
    margin-bottom: 1.5rem;
}

.form-label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 500;
    color: var(--text-color);
}

.form-input,
.form-textarea {
    width: 100%;
    padding: 0.625rem 0.75rem;
    font-size: 1rem;
    border: 1px solid var(--border-color);
    border-radius: 0.375rem;
    transition: border-color 0.2s;
}

.form-input:focus,
.form-textarea:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1);
}

.form-input.is-invalid {
    border-color: var(--error-color);
}

.form-error {
    margin-top: 0.375rem;
    font-size: 0.875rem;
    color: var(--error-color);
}

.form-actions {
    display: flex;
    gap: 0.75rem;
    margin-top: 2rem;
}

/* Detail Rows */
.detail-row {
    display: grid;
    grid-template-columns: 200px 1fr;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px solid var(--border-color);
}

.detail-row:last-child {
    border-bottom: none;
}

.detail-label {
    font-weight: 600;
    color: var(--text-light);
}

.detail-value {
    color: var(--text-color);
}

/* Alerts */
.alert {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 1rem;
    border-radius: 0.375rem;
    margin-bottom: 1.5rem;
}

.alert-success {
    background-color: var(--success-bg);
    color: var(--success-color);
    border: 1px solid var(--success-color);
}

.alert-error {
    background-color: var(--error-bg);
    color: var(--error-color);
    border: 1px solid var(--error-color);
}

.alert-icon {
    font-size: 1.25rem;
    font-weight: 700;
}

/* Empty State */
.empty-state {
    text-align: center;
    padding: 3rem 1rem;
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
}

.empty-state p {
    margin-bottom: 1rem;
    color: var(--text-light);
}

/* Info Message */
.info-message {
    background-color: #dbeafe;
    border: 1px solid #3b82f6;
    color: #1e40af;
    padding: 1rem;
    border-radius: 0.375rem;
}

.info-message p {
    margin-bottom: 0.5rem;
}

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

/* Login Page */
.login-container {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    padding: 1.5rem;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.login-box {
    width: 100%;
    max-width: 400px;
    background-color: #fff;
    border-radius: 1rem;
    padding: 2.5rem;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    text-align: center;
}

.login-title {
    font-size: 2rem;
    font-weight: 700;
    margin-bottom: 0.5rem;
    color: #667eea;
}

.login-subtitle {
    color: #666;
    margin-bottom: 2rem;
    font-size: 1rem;
}

.login-box .form-group {
    text-align: left;
}

.login-box .form-label {
    font-size: 1rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
}

.login-box .form-input {
    font-size: 1rem;
    padding: 0.875rem 1rem;
    border-radius: 0.5rem;
    width: 100%;
}

.login-box .btn-block {
    width: 100%;
    padding: 0.875rem;
    font-size: 1rem;
    font-weight: 600;
    border-radius: 0.5rem;
    margin-top: 0.5rem;
}

.login-footer {
    text-align: center;
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #eee;
    color: #999;
    font-size: 0.85rem;
}

@media (max-width: 480px) {
    .login-box {
        padding: 2rem 1.5rem;
        margin: 1rem;
    }

    .login-title {
        font-size: 1.75rem;
    }
}

/* Error Pages */
.error-container {
    text-align: center;
    padding: 4rem 1rem;
}

.error-code {
    font-size: 6rem;
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 1rem;
}

.error-title {
    font-size: 2rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.error-message {
    color: var(--text-light);
    margin-bottom: 2rem;
}

.error-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: center;
}

/* Footer */
.footer {
    background-color: var(--white);
    border-top: 1px solid var(--border-color);
    padding: 2rem 0;
    margin-top: 4rem;
    text-align: center;
    color: var(--text-light);
    font-size: 0.875rem;
}

/* Responsive */
@media (max-width: 768px) {
    .page-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .page-actions {
        width: 100%;
        flex-wrap: wrap;
    }

    .detail-row {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .table-container {
        overflow-x: auto;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn {
        width: 100%;
    }
}



/* ============================================
   Phase 2: Audio Recording & Upload Styles
   ============================================ */

/* Mode Selection */
.mode-selection {
    display: flex;
    gap: 1rem;
    margin-bottom: 2rem;
    justify-content: center;
}

.mode-btn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 1rem 2rem;
    border: 2px solid var(--border-color);
    background: var(--white);
    color: var(--text-color);
    font-size: 1rem;
    font-weight: 500;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s;
}

.mode-btn:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
}

.mode-btn.active {
    border-color: var(--primary-color);
    background: var(--primary-color);
    color: var(--white);
}

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

/* Recording Interface */
.recording-interface {
    padding: 2rem 0;
}

.recorder-container {
    max-width: 600px;
    margin: 0 auto;
}

.recorder-status {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
}

.status-indicator {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 1.1rem;
}

.status-dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: var(--secondary-color);
}

.status-dot.recording {
    background: var(--danger-color);
    animation: pulse 1.5s infinite;
}

.status-dot.paused {
    background: var(--warning-color, #f59e0b);
}

@keyframes pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.5; }
}

.timer {
    font-size: 2rem;
    font-weight: 600;
    font-family: monospace;
    color: var(--text-color);
}

/* Audio Level Meter */
.audio-level-meter {
    height: 8px;
    background: var(--border-color);
    border-radius: 4px;
    margin-bottom: 2rem;
    overflow: hidden;
}

.audio-level-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, var(--success-color), var(--primary-color));
    transition: width 0.1s;
}

/* Recorder Controls */
.recorder-controls {
    display: flex;
    justify-content: center;
    gap: 1rem;
    margin-bottom: 2rem;
}

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

.btn-record:hover {
    background: var(--danger-hover);
}

/* Recording Preview */
.recording-preview {
    border-top: 1px solid var(--border-color);
    padding-top: 2rem;
    margin-top: 2rem;
}

.recording-preview h3 {
    margin-bottom: 1rem;
}

.recording-preview audio {
    width: 100%;
    margin-bottom: 1rem;
}

.preview-info {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
    font-size: 0.95rem;
    color: var(--text-light);
}

.preview-actions {
    display: flex;
    gap: 1rem;
    justify-content: center;
}

/* Upload Interface */
.upload-interface {
    padding: 2rem 0;
}

.drop-zone {
    border: 3px dashed var(--border-color);
    border-radius: 12px;
    padding: 3rem 2rem;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s;
    background: var(--white);
}

.drop-zone:hover {
    border-color: var(--primary-color);
    background: #f0f9ff;
}

.drop-zone.drag-over {
    border-color: var(--primary-color);
    background: #f0f9ff;
    transform: scale(1.02);
}

.drop-zone svg {
    color: var(--secondary-color);
    margin-bottom: 1rem;
}

.drop-zone h3 {
    margin-bottom: 0.5rem;
    color: var(--text-color);
}

.drop-zone p {
    color: var(--text-light);
    margin: 0.5rem 0;
}

.drop-zone .help-text {
    font-size: 0.9rem;
    margin-top: 1rem;
}

/* File Preview */
.file-preview {
    margin: 2rem 0;
    padding: 1.5rem;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.file-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.file-info svg {
    color: var(--primary-color);
    flex-shrink: 0;
}

.file-details {
    flex: 1;
}

.file-name {
    font-weight: 600;
    color: var(--text-color);
    margin-bottom: 0.25rem;
}

.file-size {
    font-size: 0.9rem;
    color: var(--text-light);
}

.btn-remove {
    width: 32px;
    height: 32px;
    border: none;
    background: var(--danger-color);
    color: var(--white);
    border-radius: 50%;
    font-size: 1.5rem;
    line-height: 1;
    cursor: pointer;
    transition: background 0.2s;
}

.btn-remove:hover {
    background: var(--danger-hover);
}

/* Upload Progress */
.upload-progress {
    margin: 2rem 0;
}

.progress-container {
    height: 12px;
    background: var(--border-color);
    border-radius: 6px;
    overflow: hidden;
    margin-bottom: 0.5rem;
}

.progress-bar {
    height: 100%;
    background: linear-gradient(90deg, var(--primary-color), #60a5fa);
    transition: width 0.3s;
}

.progress-text {
    text-align: center;
    color: var(--text-light);
    font-size: 0.9rem;
}

/* Audio Player */
.audio-section {
    margin: 2rem 0;
    padding: 2rem;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.audio-section h3 {
    margin-bottom: 1.5rem;
}

.audio-player {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 8px;
    margin-bottom: 1rem;
}

.audio-player .play-btn {
    width: 48px;
    height: 48px;
    border: none;
    background: var(--primary-color);
    color: var(--white);
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s;
    flex-shrink: 0;
}

.audio-player .play-btn:hover {
    background: var(--primary-hover);
}

.audio-player .play-btn svg {
    width: 24px;
    height: 24px;
}

.audio-player .time-display {
    font-family: monospace;
    font-size: 0.9rem;
    color: var(--text-light);
    min-width: 45px;
    text-align: center;
}

.audio-player .seek-bar-container {
    flex: 1;
    position: relative;
    height: 6px;
    background: var(--border-color);
    border-radius: 3px;
}

.audio-player .seek-bar {
    position: absolute;
    width: 100%;
    height: 6px;
    -webkit-appearance: none;
    appearance: none;
    background: transparent;
    cursor: pointer;
    z-index: 2;
}

.audio-player .seek-bar::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
}

.audio-player .seek-bar::-moz-range-thumb {
    width: 16px;
    height: 16px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.audio-player .seek-bar-progress {
    position: absolute;
    height: 100%;
    background: var(--primary-color);
    border-radius: 3px;
    pointer-events: none;
}

.audio-player .speed-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.audio-player .speed-control label {
    font-size: 0.9rem;
    color: var(--text-light);
}

.audio-player .speed-select {
    padding: 0.25rem 0.5rem;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    background: var(--white);
    color: var(--text-color);
    font-size: 0.9rem;
    cursor: pointer;
}

.audio-player .volume-control {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.audio-player .volume-btn {
    width: 32px;
    height: 32px;
    border: none;
    background: transparent;
    color: var(--text-color);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.audio-player .volume-btn:hover {
    color: var(--primary-color);
}

.audio-player .volume-btn svg {
    width: 20px;
    height: 20px;
}

.audio-player .volume-slider {
    width: 80px;
    -webkit-appearance: none;
    appearance: none;
    height: 4px;
    background: var(--border-color);
    border-radius: 2px;
    cursor: pointer;
}

.audio-player .volume-slider::-webkit-slider-thumb {
    -webkit-appearance: none;
    appearance: none;
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
}

.audio-player .volume-slider::-moz-range-thumb {
    width: 12px;
    height: 12px;
    background: var(--primary-color);
    border-radius: 50%;
    cursor: pointer;
    border: none;
}

.audio-actions {
    display: flex;
    gap: 0.5rem;
}

/* Transcription Section */
.transcription-section {
    margin: 2rem 0;
    padding: 2rem;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1.5rem;
}

.section-header h3 {
    margin: 0;
}

.section-actions {
    display: flex;
    gap: 0.5rem;
}

.transcription-content {
    padding: 1.5rem;
    background: #f8fafc;
    border-radius: 6px;
    line-height: 1.8;
    white-space: pre-wrap;
    word-wrap: break-word;
    font-size: 1rem;
    color: var(--text-color);
    margin-bottom: 1rem;
    max-height: 600px;
    overflow-y: auto;
}

.transcription-meta {
    border-top: 1px solid var(--border-color);
    padding-top: 1rem;
}

/* Session Metadata */
.session-metadata {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 1.5rem;
    margin-bottom: 2rem;
    padding: 1.5rem;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.metadata-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.metadata-item label {
    font-size: 0.9rem;
    color: var(--text-light);
    font-weight: 500;
}

.metadata-item span {
    font-size: 1rem;
    color: var(--text-color);
}

/* Processing Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-content {
    background: var(--white);
    border-radius: 12px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    box-shadow: var(--shadow-md);
}

.modal-header {
    margin-bottom: 1.5rem;
}

.modal-header h3 {
    margin: 0;
    color: var(--text-color);
}

.modal-body {
    margin-bottom: 1rem;
}

.processing-steps {
    margin-top: 2rem;
}

.step {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    margin-bottom: 0.5rem;
    border-radius: 6px;
    transition: background 0.2s;
}

.step.active {
    background: #f0f9ff;
}

.step.complete {
    background: var(--success-bg);
}

.step.error {
    background: var(--error-bg);
}

.step-icon {
    font-size: 1.5rem;
}

.step-text {
    font-size: 0.95rem;
    color: var(--text-color);
}

/* Badges */
.badge {
    display: inline-block;
    padding: 0.25rem 0.75rem;
    font-size: 0.85rem;
    font-weight: 500;
    border-radius: 12px;
}

.badge-success {
    background: var(--success-bg);
    color: var(--success-color);
}

.badge-info {
    background: #dbeafe;
    color: #2563eb;
}

.badge-warning {
    background: #fef3c7;
    color: #f59e0b;
}

.badge-danger {
    background: var(--error-bg);
    color: var(--error-color);
}

.badge-secondary {
    background: #f1f5f9;
    color: var(--secondary-color);
}

/* Card Actions Bottom */
.card-actions-bottom {
    display: flex;
    gap: 1rem;
    justify-content: flex-end;
    margin-top: 2rem;
    padding-top: 2rem;
    border-top: 1px solid var(--border-color);
}

/* Browser Warning */
.alert-warning {
    background: #fef3c7;
    border: 1px solid #fde047;
    color: #92400e;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
}

.alert-info {
    background: #dbeafe;
    border: 1px solid #93c5fd;
    color: #1e40af;
    padding: 1rem;
    border-radius: 8px;
    margin: 1rem 0;
}

/* Responsive Design for Phase 2 */
@media (max-width: 768px) {
    .mode-selection {
        flex-direction: column;
    }

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

    .audio-player {
        flex-wrap: wrap;
    }

    .audio-player .speed-control,
    .audio-player .volume-control {
        flex: 1 1 100%;
        justify-content: center;
        margin-top: 0.5rem;
    }

    .session-metadata {
        grid-template-columns: 1fr;
    }

    .card-actions-bottom {
        flex-direction: column;
    }

    .card-actions-bottom button,
    .card-actions-bottom a {
        width: 100%;
    }
}



/* =====================================================
 * PHASE 3 STYLES: AI Summary & Version History
 * ===================================================== */

/* Summary Section */
.summary-section {
    margin-top: 30px;
    padding: 25px;
    background: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 8px;
}

.summary-section .section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid #dee2e6;
}

.summary-section h3 {
    margin: 0;
    color: #2c3e50;
    font-size: 1.4rem;
}

.summary-content {
    background: white;
    padding: 20px;
    border-radius: 6px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.05);
}

.summary-field {
    margin-bottom: 20px;
}

.summary-field:last-child {
    margin-bottom: 0;
}

.summary-field label {
    display: block;
    font-weight: 600;
    color: #495057;
    margin-bottom: 8px;
    font-size: 0.95rem;
}

.summary-value {
    color: #212529;
    line-height: 1.6;
    padding: 8px 0;
}

.summary-list {
    list-style: disc;
    margin-left: 25px;
    color: #212529;
}

.summary-list li {
    margin-bottom: 8px;
    line-height: 1.6;
}

.summary-meta {
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid #dee2e6;
}

/* Badge Variants */
.badge-primary {
    background-color: #007bff;
    color: white;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.85rem;
    font-weight: 500;
    display: inline-block;
    margin-right: 8px;
    margin-bottom: 8px;
}

.badge-info {
    background-color: #17a2b8;
    color: white;
}

.badge-success {
    background-color: #28a745;
    color: white;
}

.badge-secondary {
    background-color: #6c757d;
    color: white;
}

.badge-danger {
    background-color: #dc3545;
    color: white;
}

/* Version History */
.version-item {
    background: white;
    padding: 20px;
    border-radius: 6px;
    margin-bottom: 20px;
}

.version-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    padding-bottom: 10px;
    border-bottom: 1px solid #dee2e6;
}

.version-header h4 {
    margin: 0;
    color: #495057;
    font-size: 1.1rem;
}

.version-date {
    color: #6c757d;
    font-size: 0.9rem;
}

.version-content {
    line-height: 1.8;
    color: #212529;
    padding: 15px;
    background: #f8f9fa;
    border-radius: 4px;
    white-space: pre-wrap;
    word-wrap: break-word;
}

.version-footer {
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #dee2e6;
}

.version-separator {
    margin: 30px 0;
    border: 0;
    border-top: 2px dashed #dee2e6;
}

.version-meta {
    margin-bottom: 15px;
    padding: 10px;
    background: #e9ecef;
    border-radius: 4px;
}

/* Edit Forms */
.form-group label .required {
    color: #dc3545;
    margin-left: 3px;
}

.form-group textarea.form-control {
    font-family: inherit;
    resize: vertical;
    min-height: 100px;
}

.form-help {
    font-size: 0.875rem;
    color: #6c757d;
    margin-top: 5px;
    margin-bottom: 0;
}

.form-actions {
    display: flex;
    gap: 10px;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid #dee2e6;
}

.transcription-content.readonly {
    background: #f8f9fa;
    padding: 15px;
    border-radius: 4px;
    border: 1px solid #dee2e6;
    line-height: 1.8;
    color: #495057;
    white-space: pre-wrap;
    word-wrap: break-word;
}

/* Section Actions Buttons */
.section-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.section-actions .btn-sm {
    font-size: 0.875rem;
    padding: 6px 12px;
}

.section-actions svg {
    vertical-align: middle;
    margin-right: 4px;
}

/* Card Actions Bottom */
.card-actions-bottom {
    margin-top: 30px;
    padding-top: 20px;
    border-top: 2px solid #dee2e6;
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

/* Button Icon Alignment */
.btn svg {
    vertical-align: middle;
    margin-right: 5px;
}

/* Responsive Adjustments for Phase 3 */
@media (max-width: 768px) {
    .summary-section .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 15px;
    }

    .section-actions {
        width: 100%;
    }

    .section-actions .btn-sm {
        flex: 1;
        min-width: calc(50% - 4px);
    }

    .summary-field label {
        font-size: 0.9rem;
    }

    .badge-primary {
        font-size: 0.8rem;
        padding: 5px 10px;
    }

    .version-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 8px;
    }

    .form-actions {
        flex-direction: column;
    }

    .form-actions .btn {
        width: 100%;
    }

    .card-actions-bottom {
        flex-direction: column;
    }

    .card-actions-bottom .btn,
    .card-actions-bottom form {
        width: 100%;
    }
}

/* Dark Mode Support for Phase 3 (future enhancement) */
@media (prefers-color-scheme: dark) {
    .summary-section {
        background: #2c3e50;
        border-color: #34495e;
    }

    .summary-content {
        background: #34495e;
    }

    .summary-field label {
        color: #ecf0f1;
    }

    .summary-value,
    .summary-list {
        color: #ecf0f1;
    }

    .version-item {
        background: #34495e;
    }

    .version-content {
        background: #2c3e50;
        color: #ecf0f1;
    }

    .version-header h4 {
        color: #ecf0f1;
    }

    .transcription-content.readonly {
        background: #2c3e50;
        border-color: #34495e;
        color: #ecf0f1;
    }
}

/* Loading State for Summary Generation */
.summary-generating {
    text-align: center;
    padding: 40px;
    color: #6c757d;
}

.summary-generating svg {
    animation: spin 1s linear infinite;
}

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

/* Enhanced Form Styling */
.form-control:focus {
    border-color: #007bff;
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    outline: none;
}

textarea.form-control {
    line-height: 1.6;
}

/* Improved Alert Styling */
.alert {
    padding: 15px 20px;
    margin-bottom: 20px;
    border-radius: 6px;
    border-left: 4px solid;
}

.alert-info {
    background-color: #d1ecf1;
    border-color: #17a2b8;
    color: #0c5460;
}

.alert-warning {
    background-color: #fff3cd;
    border-color: #ffc107;
    color: #856404;
}

.alert strong {
    display: block;
    margin-bottom: 5px;
}

/* Print Styles for Session Reports */
@media print {
    .section-actions,
    .card-actions-bottom,
    .breadcrumb,
    header,
    nav {
        display: none !important;
    }

    .summary-section,
    .transcription-section {
        page-break-inside: avoid;
        border: 1px solid #000;
    }

    .badge {
        border: 1px solid #000;
    }
}

/* Filter Bar */
.filter-bar {
    background-color: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 0.5rem;
    padding: 1.5rem;
    margin-bottom: 1.5rem;
    box-shadow: var(--shadow);
}

.filter-form {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    align-items: flex-end;
}

.filter-group {
    flex: 1;
    min-width: 200px;
}

.filter-group .form-control {
    width: 100%;
}

.filter-actions {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

@media (max-width: 768px) {
    .filter-form {
        flex-direction: column;
    }

    .filter-group {
        width: 100%;
    }

    .filter-actions {
        width: 100%;
        justify-content: stretch;
    }

    .filter-actions .btn {
        flex: 1;
    }
}

