/* General styles */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f8fafc;
}

#root {
    width: 100%;
    margin: 0 auto;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 1rem;
}

.header {
    text-align: center;
    margin-bottom: 2rem;
}

.header h1 {
    font-size: 1.75rem;
    color: #1e293b;
    margin-bottom: 0.5rem;
}

.header p {
    color: #64748b;
    font-size: 0.9rem;
}

/* Tab navigation */
.tab-navigation {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    border-bottom: 1px solid #e2e8f0;
}

.tab-button {
    background: none;
    border: none;
    padding: 0.75rem 1rem;
    cursor: pointer;
    font-size: 0.875rem;
    color: #64748b;
    transition: all 0.2s ease;
    margin-right: 0.5rem;
    border-bottom: 2px solid transparent;
}

.tab-button:hover {
    color: #1e293b;
}

.tab-button.active {
    color: #3b82f6;
    border-bottom: 2px solid #3b82f6;
    font-weight: 600;
}

/* Form styles */
.form-container {
    margin-bottom: 1.5rem;
}

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

.form-section h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #1e293b;
}

.form-row {
    display: flex;
    flex-wrap: wrap;
    margin-bottom: 1rem;
    gap: 1rem;
}

.form-group {
    flex: 1;
    min-width: 250px;
}

.form-group.small {
    flex: 0 0 auto;
    min-width: 120px;
    width: auto;
}

.form-group.medium {
    flex: 0 0 auto;
    min-width: 180px;
    width: auto;
}

.form-label {
    display: block;
    margin-bottom: 0.375rem;
    font-size: 0.875rem;
    color: #4b5563;
    font-weight: 500;
}

.form-input, .form-select, .form-textarea {
    width: 100%;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    border: 1px solid #d1d5db;
    border-radius: 0.375rem;
    transition: border-color 0.2s ease;
}

.form-input:focus, .form-select:focus, .form-textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.25);
}

.form-textarea {
    min-height: 80px;
    resize: vertical;
}

.checkbox-group {
    display: flex;
    align-items: center;
    margin-bottom: 0.75rem;
}

.form-checkbox {
    margin-right: 0.5rem;
}

/* Main content layout */
.main-content {
    display: flex;
    gap: 1.5rem;
}

.form-panel {
    flex: 1;
    background-color: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 1.5rem;
    min-height: 500px;
    height: 600px;
    overflow-y: auto;
}

.preview-panel {
    flex: 1;
    background-color: white;
    border-radius: 0.5rem;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1);
    padding: 1.5rem;
    min-height: 500px;
    height: 600px;
    overflow-y: auto;
}

.preview-content h2 {
    font-size: 1.25rem;
    margin-bottom: 1rem;
    color: #1e293b;
}

.document-preview {
    white-space: pre-wrap;
    font-family: 'Times New Roman', Times, serif;
    font-size: 0.9rem;
    line-height: 1.5;
}

/* Highlighted text in preview */
.highlighted-text {
    background-color: #fff9c4;
    display: inline;
    padding: 2px 0;
    animation: highlight 2s;
}

@keyframes highlight {
    0% { background-color: #ffeb3b; }
    100% { background-color: #fff9c4; }
}

/* Navigation buttons */
.navigation-buttons {
    display: flex;
    justify-content: space-between;
    margin-top: 1.5rem;
}

.nav-button {
    display: flex;
    align-items: center;
    padding: 0.5rem 1rem;
    font-size: 0.875rem;
    border-radius: 0.375rem;
    cursor: pointer;
    transition: all 0.2s ease;
    background-color: white;
    border: 1px solid #d1d5db;
}

.nav-button:hover {
    background-color: #f9fafb;
}

.nav-button.disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.nav-button.next-button {
    background-color: #3b82f6;
    color: white;
    border: none;
}

.nav-button.next-button:hover {
    background-color: #2563eb;
}

/* Risk assessment styling */
.risk-assessment {
    margin-top: 1.5rem;
}

.risk-assessment h3 {
    font-size: 1.125rem;
    margin-bottom: 0.75rem;
    color: #1e293b;
}

.risk-item {
    padding: 0.75rem;
    border-radius: 0.375rem;
    margin-bottom: 0.75rem;
}

.risk-high {
    background-color: #fee2e2;
    border-left: 4px solid #ef4444;
}

.risk-medium {
    background-color: #fef3c7;
    border-left: 4px solid #f59e0b;
}

.risk-low {
    background-color: #d1fae5;
    border-left: 4px solid #10b981;
}

.risk-item h4 {
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.risk-item p {
    font-size: 0.875rem;
}

/* Icon styles */
.icon {
    width: 18px;
    height: 18px;
    stroke-width: 2;
    vertical-align: middle;
}

/* Helper classes */
.text-sm {
    font-size: 0.875rem;
}

.text-gray {
    color: #64748b;
}

.mt-2 {
    margin-top: 0.5rem;
}

.mb-2 {
    margin-bottom: 0.5rem;
}