* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Arimo', 'Noto Sans KR', sans-serif;
    background-color: #f9fafb;
    color: #101828;
}

.main-content {
    max-width: 1700px;
    margin: 0 auto;
    padding: 0px 90px;
    display: flex;
    flex-direction: column;
    gap: 31.989px;
}

/* ===== Onboarding Banner ===== */
.onboarding-banner {
    background: linear-gradient(172deg, #ffe9d6 0%, #fff4e6 50%, #ffefd5 100%);
    padding: 20px 24px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 24px;
    box-shadow: 0 1px 3px rgba(0,0,0,0.1), 0 1px 2px rgba(0,0,0,0.1);
    border-radius: 14px;
}

.onboarding-info {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.onboarding-title-row {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.onboarding-title {
    font-size: 16px;
    font-weight: 500;
    color: #1e2939;
}

.onboarding-subtitle {
    font-size: 14px;
    color: #4a5565;
}

.onboarding-progress-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.onboarding-progress-bar {
    width: 100%;
    height: 8px;
    background-color: #ffe9d6;
    border-radius: 9999px;
    overflow: hidden;
}

.onboarding-progress-fill {
    height: 100%;
    width: 40%;
    background-color: #ff7a00;
    border-radius: 9999px;
}

.onboarding-progress-label {
    font-size: 12px;
    color: #4a5565;
}

.onboarding-steps {
    display: flex;
    gap: 16px;
    align-items: center;
}

.onboarding-step {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 12px;
}

.onboarding-step .step-check {
    width: 16px;
    height: 16px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 9px;
    flex-shrink: 0;
}

.onboarding-step.done .step-check {
    background-color: #22c55e;
    color: white;
}

.onboarding-step.pending .step-check {
    border: 1.5px solid #d1d5db;
    color: transparent;
}

.onboarding-step.done .step-label {
    color: #364153;
}

.onboarding-step.pending .step-label {
    color: #99a1af;
}

.onboarding-btn {
    background-color: #ff7a00;
    color: white;
    border: none;
    border-radius: 10px;
    padding: 0 24px;
    height: 52px;
    font-size: 16px;
    font-weight: 500;
    font-family: inherit;
    cursor: pointer;
    white-space: nowrap;
    display: flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    transition: background-color 0.2s;
}

.onboarding-btn:hover {
    background-color: #e86e00;
}

/* ===== Main Layout ===== */
.main-layout {
    display: flex;
    min-height: calc(100vh - 120px - 96px);
}

/* ===== QnA Sidebar ===== */
.qna-sidebar {
    width: 240px;
    flex-shrink: 0;
    background-color: #1a2b4a;
    display: flex;
    flex-direction: column;
    border-right: 1px solid rgba(255,255,255,0.08);
}

/* Profile section */
.qna-profile-section {
    padding: 24px;
    border-bottom: 1px solid rgba(255,255,255,0.1);
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.qna-profile-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.qna-profile-icon {
    width: 40px;
    height: 40px;
    border-radius: 9999px;
    background-color: #7c3aed;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    flex-shrink: 0;
}

.qna-profile-text {
    display: flex;
    flex-direction: column;
}

.qna-profile-title {
    font-size: 16px;
    font-weight: 700;
    color: white;
}

.qna-profile-subtitle {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
}

/* Score card */
.qna-score-card {
    background-color: rgba(124,58,237,0.15);
    border: 1px solid rgba(124,58,237,0.3);
    border-radius: 10px;
    padding: 13px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.qna-score-grade-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.qna-score-grade-label {
    font-size: 11px;
    color: rgba(255,255,255,0.7);
}

.qna-grade-badge {
    background-color: #7c3aed;
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 10px;
    border-radius: 4px;
}

.qna-score-value {
    display: flex;
    align-items: baseline;
    gap: 4px;
}

.qna-score-number {
    font-size: 20px;
    font-weight: 800;
    color: #7c3aed;
}

.qna-score-unit {
    font-size: 12px;
    color: rgba(255,255,255,0.6);
}

.qna-score-progress-wrap {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.qna-score-progress-bar {
    width: 100%;
    height: 6px;
    background-color: rgba(255,255,255,0.1);
    border-radius: 9999px;
    overflow: hidden;
}

.qna-score-progress-fill {
    height: 100%;
    width: 0%;
    background-color: #7c3aed;
    border-radius: 9999px;
}

.qna-score-remaining {
    font-size: 10px;
    color: rgba(255,255,255,0.6);
}

/* Sidebar navigation */
.qna-sidebar-nav {
    padding: 16px;
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.qna-nav-btn {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 16px;
    border-radius: 10px;
    border: none;
    background-color: transparent;
    font-size: 14px;
    font-weight: 500;
    color: rgba(255,255,255,0.7);
    cursor: pointer;
    text-align: left;
    font-family: inherit;
    text-decoration: none;
    transition: all 0.2s;
}

.qna-nav-btn:hover {
    background-color: rgba(255,255,255,0.08);
    color: white;
}

.qna-nav-btn.active {
    background-color: rgba(255,107,53,0.15);
    color: #ff6b35;
    font-weight: 600;
}

.qna-nav-btn .nav-icon {
    font-size: 18px;
}

/* Monthly stats */
.qna-monthly-stats {
    padding: 0 16px 24px;
    border-top: 1px solid rgba(255,255,255,0.1);
    margin-top: auto;
}

.qna-monthly-label {
    font-size: 11px;
    color: rgba(255,255,255,0.5);
    padding: 24px 0 8px 0;
}

.qna-monthly-items {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 0 0 0 0;
}

.qna-monthly-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.qna-monthly-key {
    font-size: 12px;
    color: rgba(255,255,255,0.7);
}

.qna-monthly-val {
    font-size: 14px;
    font-weight: 700;
}

.qna-monthly-val.green { color: #22c55e; }
.qna-monthly-val.white { color: white; }
.qna-monthly-val.purple { color: #7c3aed; }

/* ===== Content Area ===== */
.qna-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

/* Content header */
.qna-content-header {
    background-color: white;
    border-bottom: 1px solid #e5e7eb;
    padding: 28px 32px 24px;
    display: flex;
    align-items: flex-end;
    justify-content: space-between;
}

.qna-content-title {
    font-size: 26px;
    font-weight: 800;
    color: #1a2b4a;
}

.qna-content-subtitle {
    font-size: 13px;
    color: #8b95a1;
    margin-top: 2px;
}

/* Content body */
.qna-content-body {
    padding: 32px 36px 48px;
    display: flex;
    flex-direction: column;
    gap: 28px;
}

/* ===== Stat Cards ===== */
.stat-cards-row {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

.stat-card {
    background-color: white;
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.stat-card-label {
    font-size: 12px;
    color: #8b95a1;
}

.stat-card-value {
    font-size: 28px;
    font-weight: 800;
    line-height: 1;
}

.stat-card-value.orange { color: #ff6b35; }
.stat-card-value.navy   { color: #1a2b4a; }
.stat-card-value.purple { color: #7c3aed; }
.stat-card-value.green  { color: #22c55e; }

.stat-card-note {
    font-size: 11px;
}

.stat-card-note.green  { color: #22c55e; }
.stat-card-note.gray   { color: #8b95a1; }
.stat-card-note.purple { color: #7c3aed; }

/* ===== Quick Link Cards ===== */
.quick-link-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px;
}

.quick-link-card {
    background-color: white;
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    padding: 20px;
    cursor: pointer;
    border: none;
    text-align: left;
    font-family: inherit;
    transition: box-shadow 0.2s;
    text-decoration: none;
    display: block;
}

.quick-link-card:hover {
    box-shadow: 0 4px 24px rgba(0,0,0,0.12);
}

.quick-link-top {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 20px;
}

.quick-link-icon {
    font-size: 32px;
    line-height: 1;
}

.quick-link-arrow {
    font-size: 14px;
    color: #ff6b35;
}

.quick-link-title {
    font-size: 16px;
    font-weight: 700;
    color: #1a2b4a;
    margin-bottom: 4px;
}

.quick-link-desc {
    font-size: 12px;
    color: #8b95a1;
}

/* ===== Question Section ===== */
.question-section {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.question-section-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.question-section-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a2b4a;
}

.question-filter-tabs {
    display: flex;
    gap: 8px;
}

.q-filter-btn {
    height: 36px;
    padding: 0 16px;
    border-radius: 10px;
    border: none;
    font-size: 13px;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
    transition: all 0.2s;
}

.q-filter-btn.active {
    background-color: #ff6b35;
    color: white;
}

.q-filter-btn.inactive {
    background-color: white;
    color: #8b95a1;
}

.q-filter-btn.inactive:hover {
    background-color: #f4f5f7;
}

/* ===== Question Cards ===== */
.question-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.question-card {
    background-color: white;
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    padding: 24px;
}

.question-card-top {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    margin-bottom: 20px;
}

.question-tags {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
}

.q-tag {
    height: 24px;
    padding: 0 12px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    display: inline-flex;
    align-items: center;
}

.q-tag.quick {
    background-color: #fff4ef;
    color: #ff6b35;
}

.q-tag.pro {
    background-color: #f0f4ff;
    color: #1a2b4a;
}

.q-tag.lang {
    background-color: #f4f5f7;
    color: #8b95a1;
    font-weight: 500;
}

.q-tag.nominated {
    background-color: #f5f3ff;
    color: #7c3aed;
}

.question-time {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    flex-shrink: 0;
}

.question-time-label {
    font-size: 11px;
    color: #8b95a1;
}

.question-time-value {
    font-size: 16px;
    font-weight: 700;
    color: #ef4444;
}

.question-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a2b4a;
    margin-bottom: 8px;
}

.question-body {
    font-size: 14px;
    color: #8b95a1;
    line-height: 1.6;
    margin-bottom: 24px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.question-card-bottom {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.question-meta {
    display: flex;
    align-items: center;
    gap: 16px;
}

.question-slots {
    display: flex;
    align-items: center;
    gap: 8px;
}

.slot-dots {
    display: flex;
    gap: 4px;
}

.slot-dot {
    width: 24px;
    height: 24px;
    border-radius: 9999px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 10px;
    font-weight: 600;
    color: white;
}

.slot-dot.filled { background-color: #ff6b35; }
.slot-dot.empty  { background-color: #f4f5f7; }

.slot-count {
    font-size: 12px;
    color: #8b95a1;
}

.question-reward {
    display: flex;
    align-items: center;
    gap: 8px;
}

.question-reward-label {
    font-size: 12px;
    color: #8b95a1;
}

.question-reward-value {
    font-size: 16px;
    font-weight: 700;
    color: #ff6b35;
}

.answer-btn {
    background-color: #ff6b35;
    color: white;
    border: none;
    border-radius: 10px;
    height: 37px;
    padding: 0 20px;
    font-size: 14px;
    font-weight: 600;
    font-family: inherit;
    cursor: pointer;
    transition: background-color 0.2s;
    flex-shrink: 0;
}

.answer-btn:hover {
    background-color: #e85c27;
}

/* ===== Answer Modal ===== */
.modal-overlay {
    display: none;
    position: fixed;
    inset: 0;
    background-color: rgba(0,0,0,0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal-overlay.open {
    display: flex;
}

.modal-box {
    background-color: #f4f5f7;
    border-radius: 10px;
    box-shadow: 0 10px 15px -3px rgba(0,0,0,0.1), 0 4px 6px -4px rgba(0,0,0,0.1);
    width: 512px;
    max-width: calc(100vw - 32px);
    max-height: calc(100vh - 48px);
    overflow-y: auto;
    display: flex;
    flex-direction: column;
}

/* Modal Header */
.modal-header {
    background-color: white;
    border-bottom: 1px solid #e5e7eb;
    padding: 0 32px;
    height: 76px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-shrink: 0;
    position: sticky;
    top: 0;
    z-index: 1;
}

.modal-header-left {
    display: flex;
    align-items: center;
    gap: 12px;
}

.modal-back-btn {
    background: none;
    border: none;
    font-size: 16px;
    color: #1a2b4a;
    cursor: pointer;
    font-family: inherit;
    padding: 0;
    white-space: nowrap;
}

.modal-back-btn:hover {
    opacity: 0.7;
}

.modal-title {
    font-size: 18px;
    font-weight: 700;
    color: #1a2b4a;
    white-space: nowrap;
}

.modal-type-badge {
    background-color: #fff4ef;
    color: #ff6b35;
    font-size: 11px;
    font-weight: 600;
    padding: 4px 12px;
    border-radius: 4px;
    white-space: nowrap;
}

.modal-type-badge.pro {
    background-color: #f0f4ff;
    color: #1a2b4a;
}

.modal-header-right {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.modal-time-label {
    font-size: 11px;
    color: #8b95a1;
}

.modal-time-value {
    font-size: 18px;
    font-weight: 700;
    color: #ef4444;
}

/* Modal Body */
.modal-body {
    padding: 24px 32px 32px;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

/* Question preview card */
.modal-question-card {
    background-color: white;
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.modal-q-title {
    font-size: 20px;
    font-weight: 700;
    color: #1a2b4a;
    line-height: 1.5;
}

.modal-q-body {
    font-size: 15px;
    color: #8b95a1;
    line-height: 1.7;
}

.ask-image-preview-row {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    margin-bottom: 6px;
}
.ask-image-preview-row:empty { display: none; }
.ask-img-thumb-wrap {
    position: relative;
    width: 70px;
    height: 70px;
    flex-shrink: 0;
    border-radius: 10px;
    overflow: hidden;
    border: 1px solid #e8ecf0;
}
.ask-img-thumb {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    cursor: pointer;
}

.ask-image-preview-text {
    color: #707983;
    font-size: 12px;
}

/* Answer writing card */
.modal-answer-card {
    background-color: white;
    border-radius: 14px;
    box-shadow: 0 2px 16px rgba(0,0,0,0.08);
    padding: 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.modal-answer-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.modal-answer-label {
    font-size: 16px;
    font-weight: 600;
    color: #1a2b4a;
}

.modal-char-count {
    font-size: 14px;
    font-weight: 600;
    color: #8b95a1;
}

.modal-textarea {
    width: 100%;
    height: 200px;
    border: 1.5px solid #e5e7eb;
    border-radius: 10px;
    padding: 16px;
    font-size: 15px;
    font-family: inherit;
    color: #1a2b4a;
    resize: none;
    outline: none;
    line-height: 1.7;
    transition: border-color 0.2s;
}

.modal-textarea::placeholder {
    color: rgba(10,10,10,0.4);
}

.modal-textarea:focus {
    border-color: #ff6b35;
}

.modal-bonus-wrap {
    display: flex;
    flex-direction: column;
    gap: 6px;
}

.modal-bonus-bar {
    width: 100%;
    height: 8px;
    background-color: #f4f5f7;
    border-radius: 9999px;
    overflow: hidden;
}

.modal-bonus-fill {
    height: 100%;
    width: 0%;
    background-color: #f59e0b;
    border-radius: 9999px;
    transition: width 0.2s;
}

.modal-bonus-text {
    font-size: 13px;
    color: #f59e0b;
}

/* Submit section */
.modal-submit-section {
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.modal-submit-btn {
    width: 100%;
    height: 56px;
    border: none;
    border-radius: 10px;
    background-color: #e5e7eb;
    color: white;
    font-size: 16px;
    font-weight: 700;
    font-family: inherit;
    cursor: not-allowed;
    transition: background-color 0.2s;
}

.modal-submit-btn.active {
    background-color: #ff6b35;
    cursor: pointer;
}

.modal-submit-btn.active:hover {
    background-color: #e85c27;
}

.modal-submit-note {
    font-size: 12px;
    color: #8b95a1;
    text-align: center;
}

/* ===== QnA Mobile Bottom Navigation ===== */
.qna-mobile-nav {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    height: 60px;
    background-color: #1a2b4a;
    border-top: 1px solid rgba(255,255,255,0.12);
    z-index: 150;
}
.qna-mobile-nav-btn {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
    color: rgba(255,255,255,0.45);
    text-decoration: none;
    transition: color 0.2s;
    height: 100%;
}
.qna-mobile-nav-icon { font-size: 20px; line-height: 1; }
.qna-mobile-nav-label { font-size: 10px; font-weight: 500; }
.qna-mobile-nav-btn.active { color: #ff6b35; }

/* ===== Responsive ===== */
@media (max-width: 1200px) {
    .stat-cards-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .quick-link-row {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (max-width: 900px) {
    .qna-sidebar { display: none; }
    .qna-mobile-nav { display: flex; }
    .main-content { padding: 24px 32px 80px; gap: 24px; }
    .qna-content-body { padding: 20px 16px; }
    .qna-content-header { padding: 16px 20px; }
}

@media (max-width: 768px) {
    .main-content { padding: 20px 20px 80px; gap: 20px; }
    .onboarding-banner { flex-direction: column; align-items: flex-start; }
    .onboarding-steps { flex-wrap: wrap; gap: 10px; }
}

@media (max-width: 600px) {
    .main-content { padding: 16px 16px 80px; gap: 16px; }
    .onboarding-banner { padding: 16px; }
    .onboarding-btn { display: none; }
    .stat-cards-row,
    .quick-link-row {
        grid-template-columns: repeat(2, 1fr);
    }
    .question-section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }
    .question-card-bottom {
        flex-direction: column;
        gap: 12px;
    }
    .answer-btn { width: 100%; }
}

@media (max-width: 480px) {
    .main-content { padding: 12px 12px 80px; }
    .stat-cards-row,
    .quick-link-row {
        grid-template-columns: 1fr;
    }
    .qna-content-title { font-size: 20px; }
    .modal-overlay { padding: 0; align-items: flex-end; }
    .modal-box {
        max-width: 100%;
        max-height: 92vh;
        border-radius: 20px 20px 0 0;
    }
}