/* /courses/assets/css/salary-guide.css */
.salary-guide-main {
    min-height: 100vh;
    background: #f0f2f5;
    padding: 2rem 0;
}

.salary-guide-main .container {
    max-width: 1200px;
}

/* ─── Page Header ────────────────────────────────────── */
.page-header {
    margin-bottom: 2rem;
}

.page-header h1 {
    font-size: 2rem;
    color: #2d3748;
    margin-bottom: 0.25rem;
}

.page-header h1 i {
    color: #48bb78;
    margin-right: 0.5rem;
}

.page-header p {
    color: #718096;
    font-size: 0.95rem;
}

/* ─── Two-Panel Layout ───────────────────────────────── */
.salary-layout {
    display: grid;
    grid-template-columns: 420px 1fr;
    gap: 2rem;
    align-items: start;
}

/* ─── Form Panel ─────────────────────────────────────── */
.salary-form-panel {
    background: white;
    border-radius: 12px;
    padding: 1.75rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
    position: sticky;
    top: 5rem;
}

.salary-form-panel .form-group {
    margin-bottom: 1.25rem;
}

.salary-form-panel label {
    display: block;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 0.4rem;
    font-size: 0.9rem;
}

.salary-form-panel .required {
    color: #e53e3e;
}

.salary-form-panel input[type="text"],
.salary-form-panel input[type="number"],
.salary-form-panel select,
.salary-form-panel textarea {
    width: 100%;
    padding: 0.6rem 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    font-size: 0.9rem;
    color: #2d3748;
    background: #f7fafc;
    transition: border-color 0.2s, box-shadow 0.2s;
    box-sizing: border-box;
}

.salary-form-panel input:focus,
.salary-form-panel select:focus,
.salary-form-panel textarea:focus {
    outline: none;
    border-color: #48bb78;
    box-shadow: 0 0 0 3px rgba(72, 187, 120, 0.15);
    background: white;
}

.salary-form-panel textarea {
    resize: vertical;
    min-height: 60px;
}

.form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

/* ─── Generate Button ────────────────────────────────── */
.btn-full {
    width: 100%;
}

.btn-lg {
    padding: 0.85rem 1.5rem;
    font-size: 1rem;
    border-radius: 10px;
}

.btn-primary {
    background: linear-gradient(135deg, #48bb78 0%, #38a169 100%);
    color: white;
    border: none;
    cursor: pointer;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    transition: transform 0.15s, box-shadow 0.15s;
}

.btn-primary:hover {
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(72, 187, 120, 0.3);
}

.btn-primary:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

/* ─── Guide History ──────────────────────────────────── */
.guide-history {
    margin-top: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid #e2e8f0;
}

.guide-history h4 {
    font-size: 0.95rem;
    color: #4a5568;
    margin-bottom: 0.75rem;
}

.history-item {
    padding: 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    margin-bottom: 0.5rem;
    transition: background 0.15s, border-color 0.15s;
}

.history-item:hover {
    background: #f7fafc;
    border-color: #48bb78;
}

.history-role {
    font-weight: 600;
    color: #2d3748;
    font-size: 0.9rem;
}

.history-meta {
    font-size: 0.8rem;
    color: #a0aec0;
    margin-top: 0.15rem;
}

/* ─── Results Panel ──────────────────────────────────── */
.salary-results-panel {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.result-section {
    background: white;
    border-radius: 12px;
    padding: 1.75rem;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.08);
}

.result-section h3 {
    font-size: 1.15rem;
    color: #2d3748;
    margin-bottom: 1.25rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.result-section h3 i {
    margin-right: 0.5rem;
    width: 20px;
    text-align: center;
}

#marketRange h3 i { color: #4299e1; }
#talkingPoints h3 i { color: #48bb78; }
#scripts h3 i { color: #ed8936; }
#culturalNotes h3 i { color: #9f7aea; }
#mistakes h3 i { color: #e53e3e; }

/* ─── Salary Range Bar ───────────────────────────────── */
.range-bar-wrapper {
    padding: 2.5rem 2rem 1rem;
    position: relative;
}

.range-bar {
    height: 12px;
    background: linear-gradient(90deg, #e2e8f0, #48bb78 50%, #38a169);
    border-radius: 6px;
    position: relative;
}

.range-marker {
    position: absolute;
    top: -8px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transform: translateX(-50%);
}

.range-min { left: 0; }
.range-median { left: 50%; }
.range-max { left: 100%; }

.range-marker::before {
    content: '';
    width: 16px;
    height: 16px;
    border-radius: 50%;
    border: 3px solid white;
    box-shadow: 0 1px 4px rgba(0, 0, 0, 0.2);
    position: absolute;
    top: 6px;
}

.range-min::before { background: #e2e8f0; }
.range-median::before { background: #48bb78; }
.range-max::before { background: #38a169; }

.range-tag {
    font-size: 0.7rem;
    color: #a0aec0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.35rem;
    white-space: nowrap;
    position: absolute;
    top: -22px;
}

.range-label {
    font-weight: 700;
    font-size: 0.85rem;
    color: #2d3748;
    margin-top: 28px;
    white-space: nowrap;
}

/* Range Values Grid */
.range-values {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 1rem;
    margin-top: 1.25rem;
    text-align: center;
}

.range-value-item {
    padding: 0.75rem;
    background: #f7fafc;
    border-radius: 8px;
}

.range-value-label {
    font-size: 0.75rem;
    color: #a0aec0;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.range-value-amount {
    font-weight: 700;
    color: #2d3748;
    font-size: 1.1rem;
}

.range-note {
    margin-top: 0.75rem;
    font-size: 0.85rem;
    color: #718096;
    font-style: italic;
    padding: 0.5rem 0.75rem;
    background: #fffaf0;
    border-radius: 6px;
    border-left: 3px solid #ed8936;
    display: none;
}

/* ─── Talking Points / Cultural / Mistakes Lists ─────── */
.point-item,
.cultural-item,
.mistake-item {
    display: flex;
    align-items: flex-start;
    gap: 0.75rem;
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f2f5;
}

.point-item:last-child,
.cultural-item:last-child,
.mistake-item:last-child {
    border-bottom: none;
}

.point-item i { color: #48bb78; margin-top: 3px; flex-shrink: 0; }
.cultural-item i { color: #9f7aea; margin-top: 3px; flex-shrink: 0; }
.mistake-item i { color: #e53e3e; margin-top: 3px; flex-shrink: 0; }

.point-item span,
.cultural-item span,
.mistake-item span {
    font-size: 0.9rem;
    color: #4a5568;
    line-height: 1.5;
}

/* ─── Script Cards ───────────────────────────────────── */
.script-card {
    background: #f7fafc;
    border-radius: 10px;
    padding: 1.25rem;
    margin-bottom: 1rem;
    border: 1px solid #e2e8f0;
}

.script-card:last-child {
    margin-bottom: 0;
}

.script-title {
    font-size: 1rem;
    color: #2d3748;
    margin-bottom: 0.5rem;
}

.script-scenario {
    font-size: 0.85rem;
    color: #718096;
    font-style: italic;
    margin-bottom: 1rem;
    padding-bottom: 0.75rem;
    border-bottom: 1px dashed #e2e8f0;
}

.script-dialogue {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.dialogue-line {
    padding: 0.75rem 1rem;
    border-radius: 10px;
    position: relative;
}

.dialogue-you {
    background: #ebf8ff;
    border-left: 3px solid #4299e1;
    margin-right: 1.5rem;
}

.dialogue-they {
    background: #fff5f5;
    border-left: 3px solid #fc8181;
    margin-left: 1.5rem;
}

.dialogue-label {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.dialogue-you .dialogue-label { color: #2b6cb0; }
.dialogue-they .dialogue-label { color: #c53030; }

.dialogue-text {
    font-size: 0.9rem;
    color: #2d3748;
    line-height: 1.55;
}

/* ─── Alerts ─────────────────────────────────────────── */
.alert {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.85rem 1rem;
    border-radius: 8px;
    margin-bottom: 1rem;
    font-size: 0.9rem;
    animation: fadeIn 0.3s ease;
}

.alert-success {
    background: #f0fff4;
    color: #276749;
    border: 1px solid #c6f6d5;
}

.alert-error {
    background: #fff5f5;
    color: #c53030;
    border: 1px solid #fed7d7;
}

.alert-warning {
    background: #fffaf0;
    color: #c05621;
    border: 1px solid #feebc8;
}

.alert-info {
    background: #ebf8ff;
    color: #2b6cb0;
    border: 1px solid #bee3f8;
}

@keyframes fadeIn {
    from { opacity: 0; transform: translateY(-8px); }
    to { opacity: 1; transform: translateY(0); }
}

/* ─── Responsive ─────────────────────────────────────── */
@media (max-width: 900px) {
    .salary-layout {
        grid-template-columns: 1fr;
    }

    .salary-form-panel {
        position: static;
    }
}

@media (max-width: 600px) {
    .salary-guide-main {
        padding: 1rem 0;
    }

    .salary-form-panel,
    .result-section {
        padding: 1.25rem;
        border-radius: 8px;
    }

    .form-row {
        grid-template-columns: 1fr;
    }

    .range-bar-wrapper {
        padding: 2rem 1rem 1rem;
    }

    .range-values {
        grid-template-columns: 1fr;
        gap: 0.5rem;
    }

    .dialogue-you { margin-right: 0.5rem; }
    .dialogue-they { margin-left: 0.5rem; }

    .page-header h1 {
        font-size: 1.5rem;
    }
}
