/* Tools Module Styles - Version 3 */

.tools-section {
    flex: 1 !important;
    display: flex;
    flex-direction: column;
    max-height: none !important;
    min-height: 0 !important;
    overflow-y: auto;
}

.tools-section .tools-list {
    flex: 1;
    overflow-y: auto;
}

/* Tool Cards */
.tool-card {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    margin-bottom: 12px;
    overflow: hidden;
    transition: box-shadow 0.2s;
    cursor: pointer;
}

.tool-card:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.08);
}

.tool-header {
    display: flex;
    align-items: center;
    padding: 16px;
    gap: 16px;
}

.tool-icon {
    width: 48px;
    height: 48px;
    border-radius: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
    flex-shrink: 0;
}

.tool-info {
    flex: 1;
    min-width: 0;
}

.tool-name {
    margin: 0 0 4px 0;
    font-size: 16px;
    font-weight: 600;
    color: #333;
    display: flex;
    align-items: center;
    gap: 8px;
}

.tool-desc {
    margin: 0;
    font-size: 13px;
    color: #666;
    line-height: 1.4;
}

.tool-launch-icon {
    width: 32px;
    height: 32px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #888;
    flex-shrink: 0;
}

/* ============================================
   Shared Tool Modal Styles
   ============================================ */

.tool-modal {
    position: fixed;
    z-index: 10000;
    background: #2d2d2d;
    border-radius: 12px;
    box-shadow: 0 8px 40px rgba(0,0,0,0.4);
    user-select: none;
    display: none;
}

.tool-modal.open {
    display: block;
}

/* Modal Header - Draggable */
.tool-modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 10px 12px;
    background: #1a1a1a;
    border-radius: 12px 12px 0 0;
    cursor: move;
}

.tool-modal-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #888;
    font-size: 13px;
    font-weight: 500;
}

.tool-modal-controls {
    display: flex;
    gap: 8px;
}

.tool-modal-btn {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    border: none;
    cursor: pointer;
    padding: 0;
}

.tool-modal-btn.close {
    background: #ff5f56;
}

.tool-modal-btn.close:hover {
    background: #ff3b30;
}

.tool-modal-btn.minimize {
    background: #ffbd2e;
}

.tool-modal-btn.minimize:hover {
    background: #ff9500;
}

/* Modal Body */
.tool-modal-body {
    padding: 15px;
}

/* Minimized state */
.tool-modal.minimized .tool-modal-body {
    display: none;
}

.tool-modal.minimized {
    min-width: 180px !important;
    max-width: 180px !important;
}

/* Keyboard hint */
.tool-keyboard-hint {
    text-align: center;
    color: #555;
    font-size: 10px;
    margin-top: 10px;
    padding-top: 10px;
    border-top: 1px solid #333;
}

/* ============================================
   Calculator Modal
   ============================================ */

.calc-modal {
    min-width: 280px;
    max-width: 340px;
}

.calc-modal .tool-modal-title i {
    color: #ff9500;
}

.calc-modal.scientific-mode {
    max-width: 380px;
}

/* Calculator Display */
.calc-display {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 12px 15px;
    margin-bottom: 12px;
    text-align: right;
}

.calc-expression {
    color: #888;
    font-size: 13px;
    min-height: 18px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    word-break: break-all;
}

.calc-result {
    color: #fff;
    font-size: 28px;
    font-weight: 300;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    word-break: break-all;
    min-height: 36px;
    line-height: 1.2;
}

/* Calculator Buttons */
.calc-buttons {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 8px;
}

.calc-btn {
    height: 48px;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.15s;
    display: flex;
    align-items: center;
    justify-content: center;
}

.calc-btn:active {
    transform: scale(0.95);
}

.calc-btn.number {
    background: #505050;
    color: #fff;
}

.calc-btn.number:hover {
    background: #606060;
}

.calc-btn.operator {
    background: #ff9500;
    color: #fff;
}

.calc-btn.operator:hover {
    background: #ffaa33;
}

.calc-btn.operator.active {
    background: #fff;
    color: #ff9500;
}

.calc-btn.function {
    background: #a0a0a0;
    color: #000;
}

.calc-btn.function:hover {
    background: #b0b0b0;
}

.calc-btn.zero {
    grid-column: span 2;
}

.calc-btn.equals {
    background: #ff9500;
    color: #fff;
}

.calc-btn.equals:hover {
    background: #ffaa33;
}

/* Scientific Mode Buttons */
.calc-scientific {
    display: none;
    grid-template-columns: repeat(5, 1fr);
    gap: 6px;
    margin-bottom: 8px;
}

.calc-modal.scientific-mode .calc-scientific {
    display: grid;
}

.calc-btn.scientific {
    height: 36px;
    font-size: 13px;
    background: #404040;
    color: #fff;
}

.calc-btn.scientific:hover {
    background: #505050;
}

/* Mode Toggle */
.calc-mode-toggle {
    display: flex;
    justify-content: center;
    margin-bottom: 12px;
}

.calc-mode-btn {
    background: none;
    border: 1px solid #505050;
    color: #888;
    padding: 5px 14px;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
}

.calc-mode-btn:first-child {
    border-radius: 5px 0 0 5px;
}

.calc-mode-btn:last-child {
    border-radius: 0 5px 5px 0;
}

.calc-mode-btn.active {
    background: #ff9500;
    border-color: #ff9500;
    color: #fff;
}

/* Memory Display */
.calc-memory {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 8px;
    padding: 0 5px;
    min-height: 16px;
}

.calc-memory-indicator {
    color: #888;
    font-size: 11px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.calc-memory-indicator.has-memory {
    color: #ff9500;
}

/* History Panel - Collapsible */
.calc-history {
    margin-top: 12px;
    padding-top: 12px;
    border-top: 1px solid #404040;
}

.calc-history-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    cursor: pointer;
    padding: 4px 0;
}

.calc-history-title {
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    display: flex;
    align-items: center;
    gap: 6px;
}

.calc-history-title i {
    font-size: 10px;
    transition: transform 0.2s;
}

.calc-history.collapsed .calc-history-title i {
    transform: rotate(-90deg);
}

.calc-history-content {
    max-height: 120px;
    overflow-y: auto;
    transition: max-height 0.3s ease;
}

.calc-history.collapsed .calc-history-content {
    max-height: 0;
    overflow: hidden;
}

.calc-history-list {
    padding-top: 8px;
}

.calc-history-item {
    color: #ccc;
    font-size: 12px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    padding: 5px 0;
    border-bottom: 1px solid #333;
    cursor: pointer;
    transition: color 0.2s;
}

.calc-history-item:hover {
    color: #ff9500;
}

.calc-history-item:last-child {
    border-bottom: none;
}

.calc-history-expr {
    color: #666;
    font-size: 10px;
}

.calc-history-result {
    color: #fff;
}

.calc-history-empty {
    color: #555;
    font-size: 11px;
    padding: 8px 0;
}

/* Clear History Button */
.calc-clear-history {
    background: none;
    border: none;
    color: #666;
    font-size: 10px;
    cursor: pointer;
    padding: 2px 6px;
}

.calc-clear-history:hover {
    color: #ff9500;
}

/* ============================================
   Unit Converter Modal
   ============================================ */

.converter-modal {
    min-width: 320px;
    max-width: 360px;
}

.converter-modal .tool-modal-title i {
    color: #007aff;
}

.converter-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #252525 100%);
}

/* Category Buttons */
.converter-categories {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 12px;
    justify-content: center;
}

.converter-category-btn {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    border: 1px solid #404040;
    background: #333;
    color: #888;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    transition: all 0.2s;
}

.converter-category-btn:hover {
    background: #404040;
    color: #fff;
}

.converter-category-btn.active {
    background: #007aff;
    border-color: #007aff;
    color: #fff;
}

.converter-category-name {
    text-align: center;
    color: #007aff;
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 16px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

/* Converter Fields */
.converter-fields {
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: center;
}

.converter-field {
    width: 100%;
}

.converter-field label {
    display: block;
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.converter-input {
    width: 100%;
    padding: 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #1a1a1a;
    color: #fff;
    font-size: 18px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    margin-bottom: 6px;
}

.converter-input:focus {
    outline: none;
    border-color: #007aff;
}

.converter-input::placeholder {
    color: #555;
}

.converter-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #333;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
}

.converter-select:focus {
    outline: none;
    border-color: #007aff;
}

/* Swap Button */
.converter-swap-btn {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #007aff;
    background: transparent;
    color: #007aff;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 16px;
    transition: all 0.2s;
    margin: 4px 0;
}

.converter-swap-btn:hover {
    background: #007aff;
    color: #fff;
    transform: rotate(180deg);
}

/* Formula Display */
.converter-formula {
    margin-top: 16px;
    padding: 12px;
    background: #1a1a1a;
    border-radius: 8px;
    text-align: center;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-size: 13px;
    color: #888;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.converter-formula span:first-child {
    color: #007aff;
}

.converter-formula span:last-child {
    color: #34c759;
}

/* ============================================
   Loan Calculator Modal
   ============================================ */

.loan-modal {
    min-width: 340px;
    max-width: 400px;
}

.loan-modal .tool-modal-title i {
    color: #34c759;
}

.loan-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #1f2a1f 100%);
}

/* Loan Inputs */
.loan-inputs {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 16px;
}

.loan-field label {
    display: block;
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.loan-input-wrapper {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border: 1px solid #404040;
    border-radius: 8px;
    overflow: hidden;
}

.loan-input-wrapper:focus-within {
    border-color: #34c759;
}

.loan-input-prefix,
.loan-input-suffix {
    padding: 12px;
    color: #888;
    font-size: 16px;
    background: #252525;
}

.loan-input {
    flex: 1;
    padding: 12px;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 18px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.loan-input:focus {
    outline: none;
}

.loan-input::placeholder {
    color: #555;
}

.loan-term-wrapper {
    display: flex;
    gap: 8px;
}

.loan-term-input {
    flex: 1;
    padding: 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #1a1a1a;
    color: #fff;
    font-size: 18px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.loan-term-input:focus {
    outline: none;
    border-color: #34c759;
}

.loan-term-select {
    padding: 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #333;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
}

.loan-term-select:focus {
    outline: none;
    border-color: #34c759;
}

/* Loan Results */
.loan-results {
    border-top: 1px solid #404040;
    padding-top: 16px;
}

.loan-result-main {
    text-align: center;
    margin-bottom: 16px;
    padding: 16px;
    background: linear-gradient(135deg, #1a3a1a 0%, #1a1a1a 100%);
    border-radius: 10px;
}

.loan-result-main .loan-result-label {
    color: #888;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 1px;
    margin-bottom: 4px;
}

.loan-result-main .loan-result-value {
    color: #34c759;
    font-size: 32px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.loan-result-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    margin-bottom: 16px;
}

.loan-result-item {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 12px;
    text-align: center;
}

.loan-result-item .loan-result-label {
    color: #888;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.loan-result-item .loan-result-value {
    color: #fff;
    font-size: 16px;
    font-weight: 500;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

/* Loan Chart */
.loan-chart {
    margin-bottom: 16px;
}

.loan-chart-bar {
    display: flex;
    height: 24px;
    border-radius: 12px;
    overflow: hidden;
    background: #1a1a1a;
}

.loan-chart-principal {
    background: #34c759;
    transition: width 0.3s ease;
}

.loan-chart-interest {
    background: #ff9500;
    transition: width 0.3s ease;
}

.loan-chart-legend {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-top: 10px;
    font-size: 12px;
}

.loan-legend-principal {
    color: #34c759;
}

.loan-legend-interest {
    color: #ff9500;
}

.loan-chart-legend i {
    font-size: 10px;
    margin-right: 4px;
}

/* Schedule Toggle */
.loan-schedule-toggle {
    width: 100%;
    padding: 10px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #333;
    color: #888;
    font-size: 13px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    transition: all 0.2s;
}

.loan-schedule-toggle:hover {
    background: #404040;
    color: #fff;
}

/* Amortization Schedule */
.loan-schedule {
    margin-top: 12px;
    max-height: 250px;
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.loan-schedule-header {
    display: grid;
    grid-template-columns: 0.7fr 1fr 1fr 1fr 1fr;
    gap: 4px;
    padding: 8px 4px;
    background: #1a1a1a;
    border-radius: 6px 6px 0 0;
    font-size: 9px;
    text-transform: uppercase;
    color: #888;
    letter-spacing: 0.3px;
    position: sticky;
    top: 0;
}

.loan-schedule-header span {
    text-align: right;
}

.loan-schedule-header span:first-child {
    text-align: left;
}

.loan-schedule-body {
    flex: 1;
    overflow-y: auto;
    background: #1a1a1a;
    border-radius: 0 0 6px 6px;
}

.loan-schedule-row {
    display: grid;
    grid-template-columns: 0.7fr 1fr 1fr 1fr 1fr;
    gap: 4px;
    padding: 6px 4px;
    font-size: 11px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    color: #ccc;
    border-bottom: 1px solid #252525;
}

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

.loan-schedule-row span {
    text-align: right;
}

.loan-schedule-row span:first-child {
    text-align: left;
    color: #888;
}

.loan-schedule-row.year-summary {
    background: #252525;
    color: #fff;
    font-weight: 500;
}

.loan-schedule-divider {
    padding: 8px 4px;
    background: #333;
    color: #007aff;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
    text-align: center;
}

/* ============================================
   Salary Lookup Modal
   ============================================ */

.salary-modal {
    min-width: 380px;
    max-width: 450px;
}

.salary-modal .tool-modal-title i {
    color: #2E7D32;
}

.salary-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #1a2a1a 100%);
}

/* Search */
.salary-search {
    margin-bottom: 12px;
}

.salary-search-wrapper {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border: 1px solid #404040;
    border-radius: 8px;
    padding: 0 12px;
}

.salary-search-wrapper:focus-within {
    border-color: #2E7D32;
}

.salary-search-icon {
    color: #888;
    font-size: 14px;
    margin-right: 10px;
}

.salary-search-input {
    flex: 1;
    padding: 12px 0;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 14px;
}

.salary-search-input:focus {
    outline: none;
}

.salary-search-input::placeholder {
    color: #666;
}

.salary-search-clear {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    border: none;
    background: #404040;
    color: #888;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
}

.salary-search-clear:hover {
    background: #505050;
    color: #fff;
}

/* Source Info */
.salary-source-info {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 8px 12px;
    background: rgba(46, 125, 50, 0.15);
    border-radius: 6px;
    margin-bottom: 12px;
    font-size: 11px;
    color: #81C784;
}

.salary-source-info i {
    font-size: 12px;
}

/* Loading */
.salary-loading {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    padding: 40px 20px;
    color: #888;
    font-size: 13px;
}

.salary-loading i {
    font-size: 18px;
    color: #2E7D32;
}

/* Results */
.salary-results {
    /* No min-height - let content determine size */
}

/* Empty State */
.salary-empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 16px 20px;
    text-align: center;
}

.salary-empty-state > i {
    font-size: 32px;
    color: #404040;
    margin-bottom: 8px;
}

.salary-empty-state > p {
    color: #888;
    font-size: 13px;
    margin: 0 0 12px 0;
}

.salary-popular {
    width: 100%;
}

.salary-popular-label {
    display: block;
    color: #666;
    font-size: 11px;
    margin-bottom: 10px;
}

.salary-popular-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
}

.salary-popular-tags button {
    padding: 6px 12px;
    border: 1px solid #404040;
    border-radius: 15px;
    background: #333;
    color: #aaa;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.salary-popular-tags button:hover {
    background: #2E7D32;
    border-color: #2E7D32;
    color: #fff;
}

/* Results List */
.salary-results-list {
    max-height: 350px;
    overflow-y: auto;
}

.salary-results-count {
    color: #888;
    font-size: 11px;
    padding: 8px 0;
    border-bottom: 1px solid #333;
    margin-bottom: 8px;
}

.salary-result-item {
    display: flex;
    align-items: flex-start;
    gap: 12px;
    padding: 12px;
    border-radius: 8px;
    cursor: pointer;
    transition: background 0.2s;
    margin-bottom: 4px;
    border: 1px solid transparent;
}

.salary-result-item:hover {
    background: #333;
    border-color: #404040;
}

.salary-result-info {
    flex: 1;
    min-width: 0;
}

.salary-result-title {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    line-height: 1.3;
}

.salary-result-code {
    color: #888;
    font-size: 11px;
    margin-top: 2px;
}

.salary-result-stats {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-top: 6px;
}

.salary-stat-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    padding: 3px 8px;
    background: #252525;
    border-radius: 12px;
    font-size: 10px;
    color: #aaa;
}

.salary-stat-pill i {
    font-size: 9px;
    color: #666;
}

.salary-result-wages {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}

.salary-result-wage-primary {
    color: #4CAF50;
    font-size: 15px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    text-align: right;
    line-height: 1.2;
}

.salary-result-wage-secondary {
    color: #888;
    font-size: 12px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    text-align: right;
    line-height: 1.2;
}

.salary-result-wage-label {
    display: block;
    font-size: 9px;
    color: #666;
    font-weight: 400;
    font-family: inherit;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.salary-result-arrow {
    color: #555;
    font-size: 12px;
    margin-top: 8px;
}

/* No Results / Error */
.salary-no-results,
.salary-error {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    text-align: center;
}

.salary-no-results i,
.salary-error i {
    font-size: 32px;
    color: #555;
    margin-bottom: 12px;
}

.salary-error i {
    color: #ff5f56;
}

.salary-no-results p,
.salary-error p {
    color: #888;
    font-size: 14px;
    margin: 0 0 4px 0;
}

.salary-no-results span,
.salary-error span {
    color: #666;
    font-size: 12px;
}

/* Detail View */
.salary-detail {
    padding: 4px 0;
}

.salary-back-btn {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 10px;
    border: none;
    border-radius: 6px;
    background: #333;
    color: #888;
    font-size: 12px;
    cursor: pointer;
    margin-bottom: 16px;
    transition: all 0.2s;
}

.salary-back-btn:hover {
    background: #404040;
    color: #fff;
}

.salary-detail-header {
    margin-bottom: 16px;
}

.salary-detail-title {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.salary-detail-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    color: #888;
    font-size: 12px;
}

.salary-detail-meta span {
    display: flex;
    align-items: center;
    gap: 4px;
}

.salary-detail-meta i {
    font-size: 10px;
}

/* Main Stats */
.salary-main-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 10px;
    margin-bottom: 16px;
}

.salary-stat-card {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 14px 12px;
    text-align: center;
}

.salary-stat-card.primary {
    background: linear-gradient(135deg, #1a3a1a 0%, #1a1a1a 100%);
    border: 1px solid #2E7D32;
}

.salary-stat-label {
    color: #888;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.salary-stat-value {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.salary-stat-card.primary .salary-stat-value {
    color: #4CAF50;
    font-size: 22px;
}

.salary-stat-hourly {
    color: #888;
    font-size: 11px;
    margin-top: 2px;
}

.salary-stat-sub {
    color: #666;
    font-size: 10px;
    margin-top: 2px;
}

/* Percentiles */
.salary-percentiles {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 12px;
}

.salary-percentiles h4 {
    color: #888;
    font-size: 12px;
    font-weight: 500;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.salary-percentiles h4 i {
    color: #2E7D32;
}

.salary-percentile-chart {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.salary-percentile-row {
    display: flex;
    align-items: center;
    gap: 10px;
}

.salary-percentile-label {
    width: 85px;
    color: #888;
    font-size: 11px;
    flex-shrink: 0;
}

.salary-percentile-bar-wrapper {
    flex: 1;
    height: 16px;
    background: #252525;
    border-radius: 4px;
    overflow: hidden;
}

.salary-percentile-bar {
    height: 100%;
    background: linear-gradient(90deg, #2E7D32, #4CAF50);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.salary-percentile-value {
    width: 80px;
    text-align: right;
    color: #fff;
    font-size: 11px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    flex-shrink: 0;
}

.salary-percentile-note {
    color: #666;
    font-size: 10px;
    margin: 12px 0 0 0;
    display: flex;
    align-items: flex-start;
    gap: 6px;
}

.salary-percentile-note i {
    color: #555;
    margin-top: 2px;
}

/* Data Year */
.salary-data-year {
    display: flex;
    align-items: center;
    justify-content: space-between;
    color: #666;
    font-size: 10px;
    padding-top: 12px;
    border-top: 1px solid #333;
}

.salary-data-year i {
    margin-right: 4px;
}

.salary-source {
    color: #555;
}

/* ============================================
   QR Code Generator Modal
   ============================================ */

.qr-modal {
    min-width: 360px;
    max-width: 420px;
}

.qr-modal .tool-modal-title i {
    color: #9C27B0;
}

.qr-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #1a1a2a 100%);
}

/* Type Selector */
.qr-type-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
}

.qr-type-btn {
    flex: 1;
    min-width: 60px;
    padding: 8px 10px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #252525;
    color: #888;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
}

.qr-type-btn i {
    font-size: 12px;
}

.qr-type-btn:hover {
    background: #333;
    border-color: #555;
    color: #fff;
}

.qr-type-btn.active {
    background: linear-gradient(135deg, #9C27B0 0%, #7B1FA2 100%);
    border-color: #9C27B0;
    color: #fff;
}

/* Input Section */
.qr-input-section {
    margin-bottom: 16px;
}

.qr-input-group {
    margin-bottom: 12px;
}

.qr-input-group:last-child {
    margin-bottom: 0;
}

.qr-input-group label {
    display: block;
    color: #888;
    font-size: 11px;
    margin-bottom: 6px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.qr-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #1a1a1a;
    color: #fff;
    font-size: 14px;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.qr-input:focus {
    outline: none;
    border-color: #9C27B0;
}

.qr-input::placeholder {
    color: #555;
}

.qr-textarea {
    min-height: 80px;
    resize: vertical;
    font-family: inherit;
}

select.qr-input {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

/* Generate Button */
.qr-generate-btn {
    width: 100%;
    padding: 12px;
    border: none;
    border-radius: 8px;
    background: linear-gradient(135deg, #9C27B0 0%, #7B1FA2 100%);
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}

.qr-generate-btn:hover {
    background: linear-gradient(135deg, #AB47BC 0%, #8E24AA 100%);
    transform: translateY(-1px);
}

.qr-generate-btn:active {
    transform: translateY(0);
}

/* Output Section */
.qr-output {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #333;
}

.qr-canvas-wrapper {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px;
    background: #fff;
    border-radius: 12px;
    margin-bottom: 12px;
    min-height: 200px;
}

/* QRCode.js creates an img element */
.qr-canvas-wrapper img {
    display: block !important;
    margin: 0 auto !important;
    max-width: 200px;
    max-height: 200px;
}

/* Action Buttons */
.qr-actions {
    display: flex;
    gap: 8px;
}

.qr-action-btn {
    flex: 1;
    padding: 10px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #252525;
    color: #aaa;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.qr-action-btn:hover {
    background: #333;
    border-color: #9C27B0;
    color: #fff;
}

.qr-action-btn i {
    font-size: 14px;
}

/* ============================================
   Tax Estimator Modal
   ============================================ */

.tax-modal {
    min-width: 380px;
    max-width: 440px;
}

.tax-modal .tool-modal-title i {
    color: #E53935;
}

.tax-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a1a1a 100%);
}

/* Year Badge */
.tax-year-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: rgba(229, 57, 53, 0.15);
    border: 1px solid rgba(229, 57, 53, 0.3);
    border-radius: 20px;
    color: #EF5350;
    font-size: 11px;
    font-weight: 500;
    margin-bottom: 16px;
}

.tax-year-badge i {
    font-size: 10px;
}

/* Tax Inputs */
.tax-inputs {
    display: flex;
    flex-direction: column;
    gap: 14px;
    margin-bottom: 16px;
}

.tax-field {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.tax-field label {
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tax-input-wrapper {
    display: flex;
    align-items: center;
    background: #1a1a1a;
    border: 1px solid #404040;
    border-radius: 8px;
    overflow: hidden;
}

.tax-input-wrapper:focus-within {
    border-color: #E53935;
}

.tax-input-prefix {
    padding: 0 0 0 12px;
    color: #888;
    font-size: 14px;
}

.tax-input {
    flex: 1;
    padding: 10px 12px;
    border: none;
    background: transparent;
    color: #fff;
    font-size: 14px;
}

.tax-input:focus {
    outline: none;
}

.tax-input::placeholder {
    color: #555;
}

.tax-select {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #1a1a1a;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%23888' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 12px center;
    padding-right: 32px;
}

.tax-select:focus {
    outline: none;
    border-color: #E53935;
}

/* Deduction Toggle */
.tax-deduction-toggle {
    display: flex;
    gap: 8px;
}

.tax-deduction-btn {
    flex: 1;
    padding: 8px 12px;
    border: 1px solid #404040;
    border-radius: 6px;
    background: #252525;
    color: #888;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
}

.tax-deduction-btn:hover {
    background: #333;
    border-color: #555;
}

.tax-deduction-btn.active {
    background: #E53935;
    border-color: #E53935;
    color: #fff;
}

.tax-deduction-amount {
    color: #888;
    font-size: 12px;
    padding: 8px 0 0 0;
}

.tax-deduction-amount strong {
    color: #fff;
}

.tax-custom-deduction {
    margin-top: 8px;
}

/* Tax Results */
.tax-results {
    background: #1a1a1a;
    border-radius: 10px;
    padding: 16px;
    margin-bottom: 12px;
}

/* Tax Summary */
.tax-summary {
    border-bottom: 1px solid #333;
    padding-bottom: 12px;
    margin-bottom: 12px;
}

.tax-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 4px 0;
    color: #888;
    font-size: 12px;
}

.tax-summary-row span:last-child {
    color: #fff;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.tax-summary-row.taxable {
    padding-top: 8px;
    margin-top: 4px;
    border-top: 1px dashed #333;
}

.tax-summary-row.taxable span:first-child {
    font-weight: 500;
    color: #aaa;
}

.tax-summary-row.taxable span:last-child {
    color: #EF5350;
    font-weight: 600;
}

/* Tax Breakdown */
.tax-breakdown {
    display: flex;
    flex-direction: column;
    gap: 10px;
    padding-bottom: 12px;
    margin-bottom: 12px;
    border-bottom: 1px solid #333;
}

.tax-breakdown-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
    padding: 10px;
    border-radius: 8px;
    background: #252525;
}

.tax-breakdown-item.federal {
    border-left: 3px solid #1976D2;
}

.tax-breakdown-item.state {
    border-left: 3px solid #7B1FA2;
}

.tax-breakdown-item.fica {
    border-left: 3px solid #388E3C;
}

.tax-breakdown-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.tax-breakdown-label {
    color: #aaa;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.tax-breakdown-rate {
    color: #666;
    font-size: 10px;
}

.tax-breakdown-value {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

/* Tax Total */
.tax-total {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.tax-total-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    color: #888;
    font-size: 12px;
}

.tax-total-row span:last-child {
    color: #fff;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    font-weight: 500;
}

.tax-total-row.effective span:last-child {
    color: #EF5350;
}

.tax-total-row.take-home {
    padding-top: 10px;
    margin-top: 4px;
    border-top: 1px solid #333;
}

.tax-total-row.take-home span:first-child {
    font-size: 13px;
    font-weight: 500;
    color: #aaa;
}

.tax-total-row.take-home span:last-child {
    font-size: 18px;
    font-weight: 600;
    color: #4CAF50;
}

.tax-monthly {
    text-align: right;
    color: #888;
    font-size: 11px;
}

.tax-monthly span {
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

/* Tax Bracket Visualization */
.tax-bracket-visual {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid #333;
}

.tax-bracket-title {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #888;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 12px;
}

.tax-bracket-title i {
    color: #E53935;
}

.tax-bracket-bars {
    display: flex;
    height: 24px;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 12px;
}

.tax-bracket-bar {
    position: relative;
    min-width: 20px;
}

.tax-bracket-bar-fill {
    height: 100%;
}

.tax-bracket-bar-fill[data-rate="10"] { background: #4CAF50; }
.tax-bracket-bar-fill[data-rate="12"] { background: #8BC34A; }
.tax-bracket-bar-fill[data-rate="22"] { background: #FFEB3B; }
.tax-bracket-bar-fill[data-rate="24"] { background: #FFC107; }
.tax-bracket-bar-fill[data-rate="32"] { background: #FF9800; }
.tax-bracket-bar-fill[data-rate="35"] { background: #FF5722; }
.tax-bracket-bar-fill[data-rate="37"] { background: #F44336; }

.tax-bracket-bar-label {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: #000;
    font-size: 9px;
    font-weight: 600;
}

.tax-bracket-legend {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.tax-bracket-legend-item {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 10px;
    color: #888;
}

.tax-bracket-legend-color {
    width: 12px;
    height: 12px;
    border-radius: 2px;
}

.tax-bracket-legend-color[data-rate="10"] { background: #4CAF50; }
.tax-bracket-legend-color[data-rate="12"] { background: #8BC34A; }
.tax-bracket-legend-color[data-rate="22"] { background: #FFEB3B; }
.tax-bracket-legend-color[data-rate="24"] { background: #FFC107; }
.tax-bracket-legend-color[data-rate="32"] { background: #FF9800; }
.tax-bracket-legend-color[data-rate="35"] { background: #FF5722; }
.tax-bracket-legend-color[data-rate="37"] { background: #F44336; }

/* Tax Disclaimer */
.tax-disclaimer {
    display: flex;
    align-items: flex-start;
    gap: 8px;
    padding: 10px;
    background: rgba(255, 152, 0, 0.1);
    border: 1px solid rgba(255, 152, 0, 0.2);
    border-radius: 6px;
    color: #FFB74D;
    font-size: 10px;
    line-height: 1.4;
}

.tax-disclaimer i {
    font-size: 12px;
    margin-top: 1px;
    flex-shrink: 0;
}

/* ============================================
   Incident Reporter Modal
   ============================================ */

.incident-modal {
    min-width: 800px;
    max-width: 1000px;
    width: calc(100vw - 100px);
}

.incident-modal .tool-modal-body {
    max-height: 80vh;
    min-height: 500px;
    overflow-y: auto;
    padding: 20px 24px;
}

.incident-modal .tool-modal-title i {
    color: #FF6B00;
}

.incident-header {
    background: linear-gradient(135deg, #1a1a1a 0%, #2a1a0a 100%);
}

/* Menu View */
.incident-menu-header {
    text-align: center;
    margin-bottom: 20px;
}

.incident-menu-header i {
    font-size: 40px;
    color: #FF6B00;
    margin-bottom: 10px;
}

.incident-menu-header h3 {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 6px 0;
}

.incident-menu-header p {
    color: #aaa;
    font-size: 12px;
    margin: 0;
}

.incident-menu-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.incident-menu-btn {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    border: 1px solid #404040;
    border-radius: 10px;
    background: #252525;
    color: #fff;
    font-size: 14px;
    cursor: pointer;
    transition: all 0.2s;
    text-align: left;
}

.incident-menu-btn:hover {
    background: #333;
    border-color: #FF6B00;
    transform: translateY(-1px);
}

.incident-menu-btn i {
    font-size: 24px;
    width: 40px;
    text-align: center;
    flex-shrink: 0;
}

.incident-menu-btn.report i {
    color: #FF6B00;
}

.incident-menu-btn.stats i {
    color: #2196F3;
}

.incident-menu-btn-text {
    flex: 1;
}

.incident-menu-btn-text strong {
    display: block;
    margin-bottom: 2px;
}

.incident-menu-btn-text span {
    font-size: 11px;
    color: #bbb;
}

.incident-menu-btn .fa-chevron-right {
    color: #555;
    font-size: 12px;
}

/* Step Indicator */
.incident-steps {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-bottom: 20px;
}

.incident-step {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: #252525;
    border-radius: 16px;
    color: #aaa;
    font-size: 11px;
    transition: all 0.2s;
}

.incident-step.active {
    background: #FF6B00;
    color: #fff;
}

.incident-step.completed {
    background: #4CAF50;
    color: #fff;
}

.incident-step i {
    font-size: 10px;
}

/* Step Content */
.incident-step-content {
    min-height: 250px;
}

.incident-step-content h4 {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    margin: 0 0 14px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.incident-step-content h4 i {
    color: #FF6B00;
}

/* Form Scroll Container (Step 2) */
.incident-form-scroll {
    max-height: 350px;
    overflow-y: auto;
    padding-right: 8px;
}

/* Incident Type Cards */
.incident-types-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
    max-height: 450px;
    overflow-y: auto;
    padding-right: 8px;
}

.incident-type-card {
    padding: 14px 16px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #252525;
    cursor: pointer;
    transition: all 0.2s;
}

.incident-type-card:hover {
    background: #333;
    border-color: #555;
}

.incident-type-card.selected {
    background: rgba(255, 107, 0, 0.15);
    border-color: #FF6B00;
}

.incident-type-card i {
    font-size: 20px;
    color: #888;
    margin-bottom: 8px;
    display: block;
}

.incident-type-card.selected i {
    color: #FF6B00;
}

.incident-type-card strong {
    display: block;
    color: #fff;
    font-size: 12px;
    margin-bottom: 4px;
}

.incident-type-card span {
    display: block;
    color: #aaa;
    font-size: 10px;
    line-height: 1.3;
}

.incident-type-group {
    grid-column: span 3;
    color: #FF6B00;
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    padding: 12px 0 6px 0;
    border-bottom: 1px solid #444;
    margin-top: 12px;
}

.incident-type-group:first-child {
    margin-top: 0;
}

/* Details Form */
.incident-field {
    margin-bottom: 14px;
}

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

.incident-field label {
    display: block;
    color: #ccc;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 6px;
}

.incident-field label .required {
    color: #FF6B00;
}

/* Other Detail Field */
.incident-other-field {
    background: rgba(255, 107, 0, 0.1);
    border: 1px solid rgba(255, 107, 0, 0.3);
    border-radius: 8px;
    padding: 12px;
    margin-bottom: 16px;
}

.incident-other-field label {
    color: #FF9500;
}

.incident-input {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #1a1a1a;
    color: #fff;
    font-size: 14px;
    transition: border-color 0.2s;
    box-sizing: border-box;
}

.incident-input:focus {
    outline: none;
    border-color: #FF6B00;
}

.incident-input::placeholder {
    color: #555;
}

.incident-textarea {
    min-height: 80px;
    resize: vertical;
    font-family: inherit;
}

.incident-char-count {
    text-align: right;
    color: #555;
    font-size: 10px;
    margin-top: 4px;
}

.incident-char-count.warning {
    color: #FF9800;
}

.incident-char-count.error {
    color: #f44336;
}

/* Optional Fields Toggle */
.incident-optional-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 10px;
    background: #1a1a1a;
    border-radius: 6px;
    color: #888;
    font-size: 12px;
    cursor: pointer;
    margin-bottom: 14px;
}

.incident-optional-toggle:hover {
    color: #fff;
}

.incident-optional-toggle i {
    font-size: 10px;
    transition: transform 0.2s;
}

.incident-optional-toggle.expanded i {
    transform: rotate(90deg);
}

.incident-optional-fields {
    display: none;
}

.incident-optional-fields.visible {
    display: block;
}

/* Severity Selection */
.incident-severity-options {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.incident-severity-option {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px;
    border: 1px solid #404040;
    border-radius: 8px;
    background: #252525;
    cursor: pointer;
    transition: all 0.2s;
}

.incident-severity-option:hover {
    background: #333;
}

.incident-severity-option.selected {
    background: #333;
    border-width: 2px;
}

.incident-severity-option.selected[data-severity="low"] {
    border-color: #4CAF50;
}

.incident-severity-option.selected[data-severity="medium"] {
    border-color: #FF9800;
}

.incident-severity-option.selected[data-severity="high"] {
    border-color: #f44336;
}

.incident-severity-option.selected[data-severity="critical"] {
    border-color: #9C27B0;
}

.incident-severity-indicator {
    width: 16px;
    height: 16px;
    border-radius: 50%;
    flex-shrink: 0;
}

.incident-severity-info {
    flex: 1;
}

.incident-severity-info strong {
    display: block;
    color: #fff;
    font-size: 14px;
    margin-bottom: 2px;
}

.incident-severity-info span {
    color: #bbb;
    font-size: 11px;
}

.incident-severity-check {
    color: #4CAF50;
    font-size: 16px;
    opacity: 0;
    transition: opacity 0.2s;
}

.incident-severity-option.selected .incident-severity-check {
    opacity: 1;
}

/* Navigation Buttons */
.incident-nav {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    margin-top: 20px;
    padding-top: 16px;
    border-top: 1px solid #333;
}

.incident-nav-btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.incident-nav-btn.back {
    background: linear-gradient(135deg, #3a3a3a 0%, #2d2d2d 100%);
    border: 1px solid #505050;
    color: #ddd;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.incident-nav-btn.back:hover {
    background: linear-gradient(135deg, #454545 0%, #383838 100%);
    border-color: #606060;
    color: #fff;
    box-shadow: 0 3px 6px rgba(0,0,0,0.25);
}

.incident-nav-btn.next,
.incident-nav-btn.submit {
    background: #FF6B00;
    border: none;
    color: #fff;
    margin-left: auto;
}

.incident-nav-btn.next:hover,
.incident-nav-btn.submit:hover {
    background: #FF8533;
}

.incident-nav-btn.submit {
    background: #4CAF50;
}

.incident-nav-btn.submit:hover {
    background: #66BB6A;
}

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

/* Stats View */
.incident-stats {
    max-height: 400px;
    overflow-y: auto;
}

.incident-stats-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.incident-stats-header h4 {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.incident-stats-header h4 i {
    color: #2196F3;
}

.incident-stats-back {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    border: 1px solid #505050;
    border-radius: 6px;
    background: linear-gradient(135deg, #3a3a3a 0%, #2d2d2d 100%);
    color: #ddd;
    font-size: 12px;
    cursor: pointer;
    transition: all 0.2s;
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

.incident-stats-back:hover {
    background: linear-gradient(135deg, #454545 0%, #383838 100%);
    border-color: #606060;
    color: #fff;
    box-shadow: 0 3px 6px rgba(0,0,0,0.25);
}

/* Stats Cards */
.incident-stats-cards {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin-bottom: 18px;
}

.incident-stat-card {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
}

.incident-stat-card.total {
    grid-column: span 4;
    background: linear-gradient(135deg, #1a2a3a 0%, #1a1a1a 100%);
    border: 1px solid rgba(33, 150, 243, 0.3);
}

.incident-stat-card .stat-value,
.incident-stat-card .incident-stat-value {
    color: #fff;
    font-size: 28px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

.incident-stat-card.total .stat-value,
.incident-stat-card.total .incident-stat-value {
    color: #2196F3;
    font-size: 36px;
}

.incident-stat-card .stat-label,
.incident-stat-card .incident-stat-label {
    color: #bbb;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 4px;
}

.incident-stat-card.critical {
    border-left: 3px solid #9C27B0;
}

.incident-stat-card.high {
    border-left: 3px solid #f44336;
}

.incident-stat-card.recent {
    border-left: 3px solid #FF9800;
}

.incident-stat-card.week {
    border-left: 3px solid #4CAF50;
}

/* Stats Breakdown Section */
.incident-stats-breakdown {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 16px;
    margin-bottom: 12px;
}

.incident-stats-breakdown h4 {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    margin: 0 0 16px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.incident-stats-breakdown h4:not(:first-child) {
    margin-top: 24px;
    padding-top: 16px;
    border-top: 1px solid #333;
}

.incident-stats-breakdown h4 i {
    color: #FF6B00;
}

/* Bar Chart Rows */
.incident-stat-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 8px 0;
}

.incident-stat-row-label {
    width: 180px;
    color: #ccc;
    font-size: 12px;
    flex-shrink: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.incident-stat-row-bar {
    flex: 1;
    height: 20px;
    background: #252525;
    border-radius: 4px;
    overflow: hidden;
}

.incident-stat-row-fill {
    height: 100%;
    background: linear-gradient(90deg, #FF6B00 0%, #FF9500 100%);
    border-radius: 4px;
    transition: width 0.3s ease;
}

.incident-stat-row-count {
    width: 40px;
    text-align: right;
    color: #fff;
    font-size: 14px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    flex-shrink: 0;
}

/* Severity Stats */
.incident-stat-severity {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 0;
    border-bottom: 1px solid #252525;
}

.incident-stat-severity:last-child {
    border-bottom: none;
}

.incident-stat-severity-badge {
    padding: 4px 12px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
    color: #fff;
}

.incident-stat-severity-count {
    color: #fff;
    font-size: 16px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

/* No Data Message */
.incident-no-data {
    color: #888;
    font-size: 13px;
    text-align: center;
    padding: 20px;
    margin: 0;
}

/* Stats Sections */
.incident-stats-section {
    background: #1a1a1a;
    border-radius: 8px;
    padding: 14px;
    margin-bottom: 12px;
}

.incident-stats-section:last-child {
    margin-bottom: 0;
}

.incident-stats-section h5 {
    color: #ccc;
    font-size: 11px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin: 0 0 12px 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.incident-stats-section h5 i {
    font-size: 12px;
}

.incident-stat-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid #252525;
}

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

.incident-stat-row span:first-child {
    color: #aaa;
    font-size: 12px;
}

.incident-stat-row span:last-child {
    color: #fff;
    font-size: 14px;
    font-weight: 500;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
}

/* Severity badge in stats */
.incident-stat-row .severity-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.incident-stat-row .severity-badge.low {
    background: rgba(76, 175, 80, 0.2);
    color: #81C784;
}

.incident-stat-row .severity-badge.medium {
    background: rgba(255, 152, 0, 0.2);
    color: #FFB74D;
}

.incident-stat-row .severity-badge.high {
    background: rgba(244, 67, 54, 0.2);
    color: #E57373;
}

.incident-stat-row .severity-badge.critical {
    background: rgba(156, 39, 176, 0.2);
    color: #BA68C8;
}

/* Status badge in stats */
.incident-stat-row .status-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 4px 10px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 500;
}

.incident-stat-row .status-badge.open {
    background: rgba(33, 150, 243, 0.2);
    color: #64B5F6;
}

.incident-stat-row .status-badge.in_progress {
    background: rgba(255, 152, 0, 0.2);
    color: #FFB74D;
}

.incident-stat-row .status-badge.resolved {
    background: rgba(76, 175, 80, 0.2);
    color: #81C784;
}

.incident-stat-row .status-badge.closed {
    background: rgba(158, 158, 158, 0.2);
    color: #BDBDBD;
}

/* Empty Stats State */
.incident-stats-empty {
    text-align: center;
    padding: 40px 20px;
}

.incident-stats-empty i {
    font-size: 48px;
    color: #333;
    margin-bottom: 16px;
}

.incident-stats-empty p {
    color: #ccc;
    font-size: 14px;
    margin: 0 0 8px 0;
}

.incident-stats-empty span {
    color: #aaa;
    font-size: 12px;
}

/* Loading State */
.incident-loading {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 40px 20px;
    gap: 12px;
}

.incident-loading i {
    font-size: 32px;
    color: #FF6B00;
}

.incident-loading span {
    color: #ccc;
    font-size: 13px;
}

/* Success State */
.incident-success {
    text-align: center;
    padding: 30px 20px;
}

.incident-success i {
    font-size: 48px;
    color: #4CAF50;
    margin-bottom: 16px;
}

.incident-success h4 {
    color: #fff;
    font-size: 18px;
    font-weight: 600;
    margin: 0 0 8px 0;
}

.incident-success p {
    color: #ccc;
    font-size: 13px;
    margin: 0 0 6px 0;
}

.incident-success .incident-key {
    display: inline-block;
    padding: 6px 14px;
    background: rgba(76, 175, 80, 0.15);
    border: 1px solid rgba(76, 175, 80, 0.3);
    border-radius: 6px;
    color: #81C784;
    font-size: 14px;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    margin: 12px 0;
}

.incident-success-actions {
    display: flex;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

.incident-success-btn {
    padding: 10px 20px;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
    display: flex;
    align-items: center;
    gap: 6px;
}

.incident-success-btn.primary {
    background: #FF6B00;
    border: none;
    color: #fff;
}

.incident-success-btn.primary:hover {
    background: #FF8533;
}

.incident-success-btn.secondary {
    background: #333;
    border: 1px solid #404040;
    color: #aaa;
}

.incident-success-btn.secondary:hover {
    background: #404040;
    color: #fff;
}

/* ============================================
   Responsive
   ============================================ */

@media (max-width: 768px) {
    .tool-modal {
        min-width: 280px !important;
        max-width: calc(100vw - 20px) !important;
    }

    .calc-btn {
        height: 44px;
        font-size: 16px;
    }

    .calc-result {
        font-size: 24px;
    }

    .converter-input {
        font-size: 16px;
    }

    .loan-input {
        font-size: 16px;
    }

    .loan-result-main .loan-result-value {
        font-size: 26px;
    }

    .salary-modal {
        min-width: 300px !important;
    }

    .salary-main-stats {
        grid-template-columns: 1fr;
    }

    .salary-stat-card.primary .salary-stat-value {
        font-size: 20px;
    }

    .incident-modal {
        min-width: 320px !important;
        max-width: calc(100vw - 20px) !important;
        width: calc(100vw - 20px) !important;
    }

    .incident-modal .tool-modal-body {
        min-height: 350px;
    }

    .incident-types-grid {
        grid-template-columns: repeat(2, 1fr);
        max-height: 350px;
    }

    .incident-type-group {
        grid-column: span 2;
    }

    .incident-stats-cards {
        grid-template-columns: repeat(2, 1fr);
    }

    .incident-stat-card.total {
        grid-column: span 2;
    }
}

@media (max-width: 480px) {
    .incident-types-grid {
        grid-template-columns: 1fr;
        max-height: 300px;
    }

    .incident-type-group {
        grid-column: span 1;
    }

    .incident-stats-cards {
        grid-template-columns: 1fr;
    }

    .incident-stat-card.total {
        grid-column: span 1;
    }
}

/* ============================================
   World Timezones Modal
   ============================================ */

.timezone-modal {
    min-width: 580px;
    max-width: 620px;
}

.timezone-modal .tool-modal-title i {
    color: #1976D2;
}

.timezone-modal-body {
    padding: 12px;
}

/* Clocks Row - Two clocks side by side */
.timezone-clocks-row {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
}

.timezone-clock-box {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 10px;
    background: #1a1a1a;
    border-radius: 8px;
    border: 1px solid #333;
}

.timezone-clock-box.local {
    border-color: rgba(25, 118, 210, 0.4);
    background: linear-gradient(135deg, #1a2a3a 0%, #1a1a2a 100%);
}

.timezone-clock-box.selected {
    border-color: rgba(76, 175, 80, 0.4);
    background: linear-gradient(135deg, #1a3a2a 0%, #1a2a1a 100%);
}

.timezone-clock-label {
    color: #888;
    font-size: 10px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 4px;
}

.timezone-clock-box.local .timezone-clock-label {
    color: #64B5F6;
}

.timezone-clock-box.selected .timezone-clock-label {
    color: #81C784;
}

.timezone-clock-time {
    color: #fff;
    font-size: 24px;
    font-weight: 300;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    letter-spacing: 1px;
}

.timezone-clock-zone {
    color: #666;
    font-size: 10px;
    margin-top: 2px;
    max-width: 100%;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Map Container */
.timezone-map-container {
    margin-bottom: 10px;
}

.timezone-map {
    display: flex;
    height: 100px;
    border-radius: 6px;
    overflow: hidden;
    background: #0a1929;
    border: 1px solid #333;
}

.timezone-zone {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-end;
    padding: 4px 1px 6px 1px;
    cursor: pointer;
    transition: all 0.15s;
    border-right: 1px solid rgba(255,255,255,0.03);
}

.timezone-zone:last-child {
    border-right: none;
}

.timezone-zone:hover {
    filter: brightness(1.3);
}

.timezone-zone.selected {
    filter: brightness(1.4);
    box-shadow: inset 0 0 0 2px #fff;
}

.timezone-zone.user-zone {
    box-shadow: inset 0 -3px 0 0 #64B5F6;
}

.timezone-zone.is-day {
    opacity: 1;
}

.timezone-zone.is-night {
    opacity: 0.7;
}

.timezone-zone-offset {
    color: rgba(255,255,255,0.95);
    font-size: 8px;
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    text-shadow: 0 1px 2px rgba(0,0,0,0.7);
    margin-bottom: 2px;
}

.timezone-zone-time {
    color: #fff;
    font-size: 9px;
    font-weight: 500;
    font-family: 'SF Mono', 'Monaco', 'Consolas', monospace;
    text-shadow: 0 1px 2px rgba(0,0,0,0.7);
}

/* Quick Cities */
.timezone-quick-cities {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-bottom: 10px;
}

.timezone-quick-city {
    padding: 5px 10px;
    border: 1px solid #404040;
    border-radius: 12px;
    background: #252525;
    color: #aaa;
    font-size: 11px;
    cursor: pointer;
    transition: all 0.15s;
}

.timezone-quick-city:hover {
    background: #333;
    border-color: #1976D2;
    color: #fff;
}

.timezone-quick-city.selected {
    background: #1976D2;
    border-color: #1976D2;
    color: #fff;
}

/* Details Panel */
.timezone-details {
    background: #1a1a1a;
    border-radius: 6px;
    padding: 10px 12px;
    min-height: 36px;
}

.timezone-detail-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.timezone-detail-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.timezone-detail-name {
    color: #fff;
    font-size: 13px;
    font-weight: 500;
}

.timezone-detail-diff {
    color: #81C784;
    font-size: 11px;
}

.timezone-detail-cities {
    display: flex;
    gap: 8px;
}

.timezone-detail-cities span {
    color: #888;
    font-size: 11px;
}

/* Responsive */
@media (max-width: 640px) {
    .timezone-modal {
        min-width: 320px !important;
        max-width: calc(100vw - 20px) !important;
    }

    .timezone-map {
        height: 80px;
    }

    .timezone-zone-offset {
        font-size: 7px;
    }

    .timezone-zone-time {
        display: none;
    }

    .timezone-clock-time {
        font-size: 20px;
    }

    .timezone-clocks-row {
        flex-direction: column;
    }
}
