/* AX2 자막 생성 인터페이스 스타일 */

/* 전역 변수 */
:root {
    --white: #FFFFFF;
    --white-soft: #FAFAFA;
    --text-dark: #1A1A1A;
    --text-light: #6B7280;
    --blue: #1E3A8A;
    --shadow-soft: rgba(0, 0, 0, 0.05);
    --shadow-medium: rgba(0, 0, 0, 0.1);
}

/* 페이지 배경 흰색으로 설정 (라이트 모드만) */
body:not(.dark-mode) {
    background: #FFFFFF !important;
    background-attachment: fixed !important;
}

/* 다크모드 배경 */
body.dark-mode {
    background: rgb(32, 33, 37) !important;
    background-attachment: fixed !important;
}

/* 메인 컨테이너 */
.main-container {
    position: relative;
    z-index: 0;
    padding: 60px 40px;
    min-height: calc(100vh - 140px);
    margin-top: 0;
    background: #FFFFFF;
}

.content-wrapper {
    max-width: 1400px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 1fr;
    gap: 30px;
    padding: 0;
}

.content-wrapper .left-panel {
    grid-column: 1 / -1;
}

/* 왼쪽 패널 */
.left-panel {
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 0;
    width: 100%;
    margin: 0 auto;
}

/* 업로드 섹션 헤더 */
.upload-section-header {
    margin-bottom: 50px;
    text-align: center;
}

.upload-title {
    font-size: 2rem;
    font-weight: 700;
    color: #000000;
    margin-bottom: 12px;
    line-height: 1.3;
}

.upload-subtitle {
    font-size: 1.1rem;
    color: #666666;
    margin: 0;
    font-weight: 400;
}

/* 드롭존 */
.drop-zone {
    width: 1400px;
    min-height: 500px;
    border-radius: 0;
    background: #FFFFFF;
    border: 2px dashed #D1D5DB;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: border-color 0.3s ease;
    position: relative;
    overflow: hidden;
    margin: 0 auto;
    padding: 60px 40px;
    user-select: none;
}

.drop-zone:hover {
    border-color: #9CA3AF;
}

.drop-zone.drag-over {
    border-color: #3B82F6;
    background: rgba(59, 130, 246, 0.05);
}

.drop-zone-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 16px;
    width: 100%;
    z-index: 1;
    position: relative;
}

.upload-icon-wrapper {
    width: 120px;
    height: 120px;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 24px;
    background: transparent;
}

.upload-icon {
    width: 80px;
    height: 80px;
    object-fit: contain;
    object-position: center;
    display: block;
    margin: 0 auto;
}

.drop-zone-text {
    font-size: 1.5rem;
    font-weight: 500;
    color: #000000;
    margin: 0;
    text-align: center;
    margin-bottom: 8px;
}

.drop-zone-file-info {
    font-size: 1.1rem;
    color: #666666;
    margin: 0;
    text-align: center;
    font-weight: 400;
}

/* 업로드 진행률 표시 */
.upload-progress-container {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 20px;
    width: 100%;
    padding: 60px 40px;
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(20, 20, 30, 0.98);
    z-index: 10;
}

.upload-progress-icon {
    font-size: 48px;
    color: #9CA3AF;
    margin-bottom: 10px;
}

.upload-progress-icon .fa-cog {
    animation: spin 2s linear infinite;
}

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

.upload-progress-bar-wrapper {
    width: 100%;
    max-width: 400px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.upload-progress-bar {
    width: 100%;
    height: 16px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.upload-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3B82F6 0%, #2563EB 100%);
    border-radius: 8px;
    transition: width 0.3s ease;
    position: relative;
}

.upload-progress-text {
    font-size: 1.2rem;
    font-weight: 600;
    color: #FFFFFF;
    text-align: center;
    margin-top: 8px;
}

/* 다크모드에서도 동일한 스타일 유지 */
body.dark-mode .upload-progress-container {
    background: rgba(20, 20, 30, 0.98);
}

body.dark-mode .upload-progress-icon {
    color: #9CA3AF;
}

body.dark-mode .upload-progress-bar {
    background: rgba(255, 255, 255, 0.1);
}

body.dark-mode .upload-progress-fill {
    background: linear-gradient(90deg, #3B82F6 0%, #2563EB 100%);
}

body.dark-mode .upload-progress-text {
    color: #FFFFFF;
}

@keyframes float-icon {
    0%, 100% {
        transform: translateY(0);
    }
    50% {
        transform: translateY(-10px);
    }
}

/* 번역 설정 모달 */
.translation-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 2000;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 1;
    overflow: hidden;
}

.modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.05);
    backdrop-filter: blur(12px);
}

.modal-content-wrapper {
    position: relative;
    z-index: 2001;
    width: 95%;
    max-width: 1400px;
    max-height: 95vh;
    overflow: visible;
    display: flex;
    align-items: center;
    justify-content: center;
}

.translation-modal-container {
    background: #ffffff;
    border-radius: 8px;
    padding: 35px 35px 35px 35px;
    width: 100%;
    max-width: 940px;
    max-height: 90vh;
    overflow: visible;
    display: flex;
    flex-direction: column;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.12);
    border: 1px solid #e5e7eb;
    position: relative;
}

.modal-close-btn {
    position: absolute;
    top: -2px;
    right: -3px;
    background: transparent;
    border: none;
    color: #6b7280;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 12px;
    border-radius: 0;
    width: 44px;
    height: 44px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s ease;
    z-index: 10;
    text-shadow: none;
}

.modal-close-btn:hover {
    background: transparent;
    color: #111827;
    transform: none;
    text-shadow: none;
}

.translation-layout {
    display: grid;
    grid-template-columns: 1fr 380px;
    gap: 24px;
    align-items: start;
    min-width: 0;
    overflow: visible;
}

/* 왼쪽: Video preview + Subtitle settings */
.left-column {
    display: flex;
    flex-direction: column;
    overflow-y: auto;
    overflow-x: visible;
    padding-right: 8px;
    min-width: 0;
}

.left-column::-webkit-scrollbar {
    width: 6px;
}

.left-column::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 10px;
}

.left-column::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}

.left-column::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

.video-preview-section {
    margin-bottom: 0;
    padding-bottom: 16px;
    border-bottom: 1px solid #e5e7eb;
}

.video-container {
    width: 100%;
    max-width: 100%;
    max-height: 265px;
    aspect-ratio: 16 / 9;
    background: #0a0a0a;
    border-radius: 8px;
    overflow: hidden;
    position: relative;
    margin: 0 auto;
    border: none;
}

.video-preview {
    width: 100%;
    height: 100%;
    object-fit: contain;
    background: #000;
    border-radius: 8px;
    pointer-events: auto;
}

.video-preview-divider {
    display: none;
}

/* Subtitle settings 섹션 */
.subtitle-settings-section {
    flex: 1;
    min-width: 0;
    overflow: visible;
}

.subtitle-settings-title {
    display: none;
}

/* 수평 언어 플로우 레이아웃 */
.language-flow-container {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    min-height: 100px;
    margin-top: 10px;
}

.language-flow-item {
    display: flex;
    flex-direction: column;
    gap: 10px;
    flex: 0 0 auto;
    align-items: flex-start;
}

.language-flow-item .language-chip {
    height: 44px;
    min-height: 44px;
    max-height: 44px;
}

.language-flow-item.language-flow-to {
    flex: 1;
    min-width: 0;
}

.language-flow-label {
    font-size: 16px;
    font-weight: 600;
    color: #aaa;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 4px;
}

.language-flow-arrow {
    display: flex;
    align-items: center;
    padding-top: 50px;
    color: #666;
    font-size: 18px;
}

.target-language-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    align-items: center;
    min-height: 44px;
    overflow: visible;
}

.target-language-chips .language-chip:hover {
    transform: none !important;
    background: rgba(255, 0, 0, 0.1) !important;
    border-color: rgba(255, 0, 0, 0.3) !important;
}

/* 언어 칩 스타일 */
.language-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: #e5e7eb;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    font-size: 16px;
    font-weight: 500;
    color: #111827;
    transition: all 0.2s ease;
    cursor: default;
    position: relative;
    white-space: nowrap;
    height: 44px;
    min-height: 44px;
    max-height: 44px;
    box-sizing: border-box;
    line-height: 1;
}

.language-chip *,
.language-chip .chip-credit,
.language-chip .language-name {
    font-size: 16px;
    font-weight: 600;
}

.language-chip.original-language-chip {
    background: #f3f4f6;
    border: 1px solid #d1d5db;
    color: #111827;
    cursor: pointer;
}

.language-chip.original-language-chip:hover {
    border-color: #9ca3af;
    background: #e5e7eb;
}

.language-chip .credit-icon {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: none;
}

.language-chip.original-language-chip .credit-icon {
    filter: none;
}

.target-language-chips .language-chip .credit-icon,
.target-language-chips .language-chip img.credit-icon {
    filter: none !important;
}

.language-chip .chip-credit {
    font-weight: 600;
    color: #000000;
    font-size: 16px;
}

.language-chip.original-language-chip .chip-credit {
    font-weight: 600;
}

.add-language-chip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    padding: 10px 14px;
    background: transparent;
    border: 1px dashed #9ca3af;
    border-radius: 4px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #6b7280;
    font-size: 14px;
    font-weight: 500;
    white-space: nowrap;
    height: 44px;
    min-height: 44px;
    max-height: 44px;
    box-sizing: border-box;
    position: relative;
    line-height: 1;
}

.add-language-chip:hover {
    border-color: #6b7280;
    background: #f9fafb;
    color: #111827;
    transform: none;
}

.add-language-chip i {
    font-size: 16px;
}

.add-language-chip * {
    font-size: 16px;
    color: #6b7280;
}

/* 언어 옵션 카드 (선택 가능한, 수평 배치) */
.language-option-card {
    display: inline-flex;
    align-items: center;
    padding: 10px 14px;
    background: #e5e7eb;
    border: 1px solid #d1d5db;
    border-radius: 4px;
    cursor: pointer;
    position: relative;
    overflow: visible;
    white-space: nowrap;
    height: 44px;
    min-height: 44px;
    max-height: 44px;
    box-sizing: border-box;
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    line-height: 1;
}

.language-option-card * {
    font-size: 14px;
}

.language-option-card:hover {
    border-color: #9ca3af;
    background: #d1d5db;
    transform: none;
}

.language-option-card.selected {
    border-color: #6b7280;
    background: #d1d5db;
}

.language-option-card .language-name {
    font-size: 16px;
    font-weight: 500;
    color: #111827;
    line-height: 1;
}

.language-option-card .language-credit {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
    color: #111827;
    line-height: 1;
    margin-left: 8px;
}

.language-option-card .language-credit span {
    font-size: 16px;
    color: #000000;
    font-weight: 600;
}

.language-option-card .language-credit img {
    width: 18px;
    height: 18px;
    min-width: 18px;
    min-height: 18px;
    object-fit: contain;
    display: block;
    flex-shrink: 0;
}

.language-option-card .remove-btn {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 22px;
    height: 22px;
    border-radius: 50%;
    border: 1px solid #d1d5db;
    background: #ffffff;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 11px;
    transition: all 0.2s ease;
    flex-shrink: 0;
    z-index: 10;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.15);
    padding: 0;
    margin: 0;
    line-height: 1;
    text-align: center;
}

.language-option-card .remove-btn i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    line-height: 1;
    margin: 0;
    padding: 0;
    transform: translateX(0.5px);
}

.language-option-card .remove-btn:hover {
    background: #000000;
    border-color: rgba(59, 130, 246, 0.5);
    color: #3b82f6;
}

/* 오른쪽: Credit summary */
.credit-summary-column {
    display: flex;
    flex-direction: column;
    overflow: visible;
}

.credit-summary-column::-webkit-scrollbar {
    width: 6px;
}

.credit-summary-column::-webkit-scrollbar-track {
    background: #f3f4f6;
    border-radius: 10px;
}

.credit-summary-column::-webkit-scrollbar-thumb {
    background: #d1d5db;
    border-radius: 10px;
}

.credit-summary-column::-webkit-scrollbar-thumb:hover {
    background: #9ca3af;
}

.credit-summary-card {
    background: #f9fafb;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 20px;
    display: flex;
    flex-direction: column;
    position: relative;
}

.credit-summary-title {
    font-size: 16px;
    font-weight: 600;
    color: #111827;
    margin: 0 0 4px 0;
    letter-spacing: -0.01em;
}

/* 크레딧 정보 */
.point-info-section {
    margin-bottom: 20px;
    padding-bottom: 20px;
    border-bottom: 1px solid #e5e7eb;
    flex: 0 0 auto;
}

.point-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 12px;
}

.point-info-item:last-child {
    margin-bottom: 0;
}

.point-info-label {
    font-size: 16px;
    color: #6b7280;
    font-weight: 600;
    line-height: 1.4;
}

.point-info-value {
    font-size: 16px;
    color: #000000;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 6px;
    line-height: 1.4;
}

.point-info-value .credit-icon-small {
    width: 16px;
    height: 16px;
    object-fit: contain;
    filter: none;
}

.point-deducted {
    color: #000000;
}

.point-remaining {
    color: #10b981;
}

.point-remaining.negative {
    color: #ef4444 !important;
}

.point-remaining.negative span {
    color: #ef4444 !important;
}

/* 결제 방법 선택 섹션 */
.payment-method-section {
    margin-bottom: 20px;
    margin-top: auto;
    flex: 0 0 auto;
}

.credit-charge-packages-inline {
    display: flex;
    gap: 10px;
    justify-content: space-between;
    flex-wrap: nowrap;
    margin-top: 12px;
    width: 100%;
    padding-bottom: 8px;
}

.credit-charge-packages-inline .credit-charge-package-card {
    flex: 1;
    min-width: 0;
    max-width: none;
    padding: 16px 12px 12px 12px;
    min-height: 120px;
}

/* 생성 버튼 */
.generate-subtitle-btn {
    width: 100%;
    padding: 14px 20px;
    background: #2a2a2a;
    color: #666;
    border: 1px solid #2a2a2a;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: not-allowed;
    display: flex;
    align-items: center;
    justify-content: space-between;
    transition: all 0.2s ease;
    pointer-events: none;
    margin-top: auto;
    flex: 0 0 auto;
}

.generate-subtitle-btn:enabled {
    background: #1E3A8A;
    color: #ffffff;
    border-color: #1E3A8A;
    cursor: pointer;
    pointer-events: auto;
}

.generate-subtitle-btn:enabled:hover {
    background: #1e40af;
    border-color: #1e40af;
}

.generate-btn-credit {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 15px;
    font-weight: 600;
    opacity: 0.9;
}

.generate-subtitle-btn .credit-icon-small {
    width: 18px;
    height: 18px;
    object-fit: contain;
    filter: none;
}

/* 진행 상태 */
.translate-btn-progress {
    display: none;
    flex-direction: column;
    width: 100%;
    gap: 0;
    margin: 0;
    padding: 16px 24px 20px 24px;
    background: rgba(30, 58, 138, 0.1);
    border-radius: 12px;
    border: 1px solid rgba(30, 58, 138, 0.2);
    min-width: 300px;
    min-height: 120px;
    box-sizing: border-box;
    position: static !important;
    z-index: 1000;
}

.translate-btn-progress.show-progress {
    display: flex !important;
    visibility: visible !important;
    opacity: 1 !important;
}

.translate-btn-progress-text {
    font-size: 0.95rem;
    color: #1E3A8A;
    text-align: center;
    font-weight: 600;
    margin-bottom: 12px;
    margin-top: 0;
    white-space: normal;
    word-wrap: break-word;
    overflow-wrap: break-word;
    min-width: 0;
    width: 100%;
    box-sizing: border-box;
}

.translate-btn-progress-bar {
    width: 100%;
    height: 16px;
    min-height: 16px;
    background: rgba(30, 58, 138, 0.2);
    border-radius: 3px;
    overflow: hidden;
    display: block;
    visibility: visible;
    opacity: 1;
    flex-shrink: 0;
    margin-bottom: 0;
}

.translate-btn-progress-fill {
    height: 100%;
    background: #1E3A8A;
    border-radius: 3px;
    transition: width 0.3s ease;
}

/* 크레딧 충전 모달 */
.credit-charge-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 10000;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 24px;
    pointer-events: none;
}

.credit-charge-modal[style*="display: flex"],
.credit-charge-modal[style*="display:block"] {
    pointer-events: auto;
}

.credit-charge-modal-backdrop {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
}

.credit-charge-modal-content {
    position: relative;
    background: #FFFFFF;
    border-radius: 20px;
    padding: 0;
    max-width: 1200px;
    width: 100%;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.05);
    z-index: 10001;
    display: flex;
    flex-direction: column;
    max-height: 90vh;
    overflow: hidden;
}

.credit-charge-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 16px 16px 28px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    background: rgba(255, 255, 255, 1);
}

.credit-charge-modal-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    letter-spacing: -0.01em;
}

.credit-charge-modal-close {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 10px;
    background: transparent;
    color: #6b7280;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    font-size: 18px;
}

.credit-charge-modal-close:hover {
    background: #f3f4f6;
    color: #111827;
    transform: rotate(90deg);
}

.credit-charge-packages {
    display: flex;
    gap: 12px;
    justify-content: center;
    flex-wrap: wrap;
    padding: 20px;
    overflow-y: auto;
}

/* 크레딧 충전 패키지 카드 */
.credit-charge-package-card {
    position: relative;
    background: #ffffff;
    border: 1px solid #e5e7eb;
    border-radius: 8px;
    padding: 12px 10px 8px 10px;
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: border-color 0.3s ease;
    cursor: pointer;
    min-height: 10px;
    flex: 1 1 0;
    min-width: 180px;
    max-width: 280px;
}

.credit-charge-package-card:hover {
    border-color: #d1d5db;
}

.credit-charge-package-card.selected {
    border: 2px solid #3b82f6 !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2) !important;
    background: #ffffff !important;
}

.credit-charge-package-card.popular {
    border: 1px solid #e5e7eb;
}

.credit-charge-package-card.popular.selected {
    border: 2px solid #3b82f6 !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2) !important;
    background: #ffffff !important;
}

.credit-package-badge {
    position: absolute;
    top: -8px;
    padding: 4px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 700;
    white-space: nowrap;
    z-index: 1;
    box-shadow: none;
}

.credit-package-badge.discount {
    left: 10px;
    background: #EF4444;
    color: #FFFFFF;
}

.credit-package-badge.popular-badge {
    background: #FF7F50;
    color: #FFFFFF;
    box-shadow: none;
}

.credit-package-badge.recommended-badge {
    background: #FF9500;
    color: #FFFFFF;
    box-shadow: none;
}

.credit-package-badges {
    position: absolute;
    top: -8px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 6px;
    z-index: 1;
    flex-wrap: wrap;
}

.credit-package-badges .credit-package-badge {
    position: relative;
    top: 0;
    left: 0;
    right: 0;
}

.credit-package-description {
    font-size: 11px;
    color: #6b7280;
    margin-bottom: 10px;
    line-height: 1.3;
    margin-top: 6px;
    text-align: center;
    min-height: 24px;
}

.credit-package-description .credit-duration-number {
    font-weight: 700;
    color: #111827;
    font-size: 12px;
}

.credit-package-amount {
    font-size: 1.2rem;
    font-weight: 700;
    color: #111827;
    margin-bottom: 6px;
    margin-top: 4px;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2px;
}

.credit-package-amount .credit-unit-text {
    font-size: 0.9rem;
    font-weight: 500;
    color: #6b7280;
}

.credit-package-price {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
    margin-bottom: 0;
}

.credit-package-price-row {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.credit-package-original-price {
    font-size: 11px;
    font-weight: 400;
    color: #9CA3AF;
    text-decoration: line-through;
    text-decoration-color: #EF4444;
    text-decoration-thickness: 2px;
    min-height: 12px;
}

.credit-package-discounted-price {
    font-size: 18px;
    font-weight: 700;
    color: #3b82f6;
    line-height: 1.2;
}

.credit-price-unit {
    font-size: 16px;
    font-weight: 400;
}

.credit-price-unit-small {
    font-size: 0.6em;
    font-weight: 400;
}

.credit-package-original-price .credit-price-unit {
    font-size: 11px;
    font-weight: 400;
}

.credit-package-discount-label {
    font-size: 14px;
    color: #9CA3AF;
    font-weight: 500;
}

.credit-package-icon {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 8px;
    font-size: 16px;
    color: #ffffff;
}

.credit-charge-package-card.popular .credit-package-icon {
    background: rgba(102, 126, 234, 0.2);
    color: #667eea;
}

/* 언어 선택 모달 */
.language-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    backdrop-filter: blur(8px);
    z-index: 3000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.language-modal .modal-content {
    background: #ffffff;
    border-radius: 20px;
    border: none;
    padding: 0;
    max-width: 700px;
    width: 100%;
    max-height: 85vh;
    overflow: hidden;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.15);
    display: flex;
    flex-direction: column;
}

.language-modal .modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 18px 28px 16px 28px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    background: #ffffff;
}

.language-modal .modal-header h3 {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0;
    letter-spacing: -0.01em;
}

.language-modal .modal-header-subtitle {
    font-size: 14px;
    font-weight: 500;
    color: #6b7280;
    margin: 0;
    letter-spacing: -0.01em;
}

.language-modal .modal-close {
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 10px;
    background: transparent !important;
    color: #111827;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
}

.language-modal .modal-close:hover {
    background: transparent;
    color: #111827;
    transform: none;
}

.language-modal .modal-body {
    padding: 18px 28px;
    overflow-y: auto;
    flex: 1;
    scrollbar-width: thin;
    scrollbar-color: rgba(0, 0, 0, 0.2) transparent;
}

.language-modal .modal-body::-webkit-scrollbar {
    width: 6px;
}

.language-modal .modal-body::-webkit-scrollbar-track {
    background: transparent;
}

.language-modal .modal-body::-webkit-scrollbar-thumb {
    background: rgba(0, 0, 0, 0.2);
    border-radius: 3px;
}

.language-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 8px;
}

.modal-language-item {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px 16px;
    border-radius: 10px;
    background: #ffffff;
    border: 1.5px solid #e5e7eb;
    cursor: pointer;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.modal-language-item:hover {
    background: #f9fafb;
    border-color: #1E3A8A;
    color: #1E3A8A;
    transform: none;
    box-shadow: 0 4px 12px rgba(30, 58, 138, 0.15);
}

.modal-language-item.selected {
    background: #1E3A8A;
    border-color: #1E3A8A;
    color: #ffffff;
    box-shadow: 0 4px 14px rgba(30, 58, 138, 0.25);
}

/* 결제 모달 */
.payment-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 30000 !important;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
}

.payment-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.payment-modal {
    background: white;
    width: 100%;
    max-width: 900px;
    max-height: 85vh;
    height: auto;
    overflow: hidden;
    border-radius: 24px;
    position: relative;
    transform: translateY(20px);
    transition: transform 0.3s ease;
    box-shadow: 0 8px 32px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
}

.payment-modal-overlay.active .payment-modal {
    transform: translateY(0);
}

.payment-modal-close {
    position: absolute;
    top: 20px;
    right: 20px;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 24px;
    color: #666;
    transition: all 0.2s ease;
    z-index: 10;
}

.payment-modal-close:hover {
    color: #1a1a2e;
}

.payment-modal-body {
    padding: 0;
    display: flex;
    flex-direction: row;
    flex: 1;
    overflow: hidden;
    min-height: 0;
    max-height: calc(85vh - 60px);
}

.payment-methods-container {
    flex: 1;
    padding: 24px;
    overflow-y: auto;
    overflow-x: hidden;
    border-right: 1px solid #E5E7EB;
    background: white;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.payment-main-title {
    font-size: 18px;
    font-weight: 600;
    color: #1a1a2e;
    margin-bottom: 24px;
}

.payment-section {
    margin-bottom: 24px;
}

.payment-section-title {
    font-size: 16px;
    font-weight: 600;
    color: #999;
    margin-bottom: 12px;
}

.payment-methods {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 16px;
    margin-bottom: 8px;
}

.payment-methods.cards {
    grid-template-columns: repeat(3, 1fr);
}

.payment-method-btn {
    padding: 16px 12px;
    border: 1px solid #E5E7EB;
    border-radius: 16px;
    background: white;
    font-size: 14px;
    color: #1a1a2e;
    cursor: pointer;
    transition: all 0.2s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    min-height: 100px;
    width: 100%;
    height: auto;
    position: relative;
}

.payment-method-btn:hover {
    border-color: #1E3A8A;
    box-shadow: 0 2px 12px rgba(30, 58, 138, 0.12);
}

.payment-method-btn.active {
    border-color: #2a2a2a;
    background: #252525;
    box-shadow: none;
}

.payment-method-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 8px;
    width: 100%;
}

.payment-method-badge {
    position: absolute;
    top: -8px;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 11px;
    font-weight: 600;
    z-index: 10;
}

.payment-method-badge.discount {
    left: 8px;
    background: #ef4444;
    color: #ffffff;
}

.payment-method-badge.popular {
    right: 8px;
    background: #3b82f6;
    color: #ffffff;
}

.payment-method-description {
    font-size: 12px;
    color: #6b7280;
    text-align: center;
    line-height: 1.4;
    margin-top: 8px;
}

.payment-method-credit {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
    text-align: center;
}

.payment-method-credit-amount {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1;
}

.payment-method-credit-label {
    font-size: 16px;
    font-weight: 500;
    color: #ffffff;
    line-height: 1;
}

.payment-method-price {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 4px;
}

.payment-method-original-price {
    font-size: 16px;
    color: #6b7280;
    text-decoration: line-through;
    line-height: 1;
}

.payment-method-discounted-price {
    font-size: 16px;
    font-weight: 700;
    color: #ffffff;
    line-height: 1;
    display: flex;
    align-items: baseline;
    gap: 2px;
}

.payment-method-price-unit {
    font-size: 16px;
    font-weight: 500;
    color: #ffffff;
}

.payment-method-btn.active .payment-method-discounted-price {
    color: #ffffff;
}

.payment-method-btn.active .payment-method-price-unit {
    color: #ffffff;
}

.payment-more-link {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    color: #666;
    font-size: 14px;
    margin-top: 16px;
    cursor: pointer;
    text-decoration: none;
}

.payment-more-link:hover {
    color: #1E3A8A;
}

.payment-summary-container {
    width: 320px;
    flex-shrink: 0;
    padding: 24px;
    background: #F9FAFB;
    display: flex;
    flex-direction: column;
    position: relative;
    overflow-y: auto;
    overflow-x: hidden;
}

.payment-summary-item {
    margin-bottom: 16px;
}

.payment-summary-label {
    font-size: 15px;
    color: #999;
    margin-bottom: 6px;
}

.payment-summary-value {
    font-size: 16px;
    font-weight: 600;
    color: #1a1a2e;
    line-height: 1.4;
}

.payment-summary-amount {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a2e;
    margin-top: 4px;
}

.terms-box {
    background: #F9FAFB;
    border: 1px solid #E5E7EB;
    border-radius: 8px;
    padding: 16px;
    font-size: 13px;
    color: #374151;
    line-height: 1.6;
}

.terms-box strong {
    font-size: 14px;
    font-weight: 600;
    color: #1a1a2e;
    display: block;
    margin-bottom: 12px;
}

.terms-box a {
    color: #1E3A8A;
    text-decoration: underline;
    font-weight: 500;
    transition: color 0.2s ease;
}

.terms-agreement {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
    font-size: 14px;
    color: #666;
}

.terms-agreement input[type="checkbox"] {
    width: 18px;
    height: 18px;
    cursor: pointer;
}

.payment-submit-btn {
    width: 100%;
    padding: 18px;
    background: #1a1a2e;
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 18px;
    font-weight: 600;
    cursor: pointer;
    transition: background 0.2s ease;
}

.payment-submit-btn:hover {
    background: #2d2d44;
}

.payment-submit-btn:disabled {
    background: #E5E7EB;
    color: #9CA3AF;
    cursor: not-allowed;
}

/* 결제 완료 모달 */
.payment-success-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.6);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 20001;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.25s cubic-bezier(0.4, 0, 0.2, 1), visibility 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    padding: 24px;
    box-sizing: border-box;
}

.payment-success-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.payment-success-modal {
    background: #ffffff;
    border-radius: 20px;
    width: 100%;
    max-width: 480px;
    padding: 0;
    box-shadow: 0 24px 48px rgba(0, 0, 0, 0.15), 0 0 0 1px rgba(0, 0, 0, 0.05);
    transform: scale(0.95) translateY(10px);
    transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    overflow: hidden;
    display: flex;
    flex-direction: column;
}

.payment-success-modal-overlay.active .payment-success-modal {
    transform: scale(1) translateY(0);
}

.payment-success-content {
    padding: 32px 28px 24px 28px;
    text-align: center;
}

.payment-success-icon {
    font-size: 48px;
    color: #22c55e;
    margin: 0 auto 20px auto;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #d1fae5;
}

.payment-success-content h2 {
    font-size: 20px;
    font-weight: 700;
    color: #111827;
    margin: 0 0 12px 0;
    letter-spacing: -0.01em;
    text-align: center;
}

.payment-success-info {
    margin-bottom: 24px;
    background: #f9fafb;
    border-radius: 8px;
    padding: 16px;
    text-align: center;
}

.success-info-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 8px 0;
    border-bottom: 1px solid rgba(0, 0, 0, 0.06);
}

.success-info-item:last-child {
    border-bottom: none;
    padding-bottom: 0;
}

.success-info-label {
    font-size: 14px;
    color: #6b7280;
    font-weight: 400;
}

.success-info-value {
    font-size: 15px;
    font-weight: 600;
    color: #111827;
    letter-spacing: -0.01em;
}

.payment-success-btn {
    width: 100%;
    padding: 12px 24px;
    background: #111827;
    color: #ffffff;
    border: none;
    border-radius: 8px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    letter-spacing: -0.01em;
}

.payment-success-btn:hover {
    background: #1f2937;
}

/* 다크모드 스타일 */
body.dark-mode .main-container {
    background: rgb(32, 33, 37);
}

body.dark-mode .upload-title,
body.dark-mode .upload-subtitle {
    color: #f1f5f9;
}

body.dark-mode .drop-zone {
    background: rgb(32, 33, 37) !important;
    border: 2px dashed rgba(148, 163, 184, 0.6) !important;
    color: #0080ff;
}

body.dark-mode .drop-zone:hover {
    border: 2px dashed rgba(148, 163, 184, 0.6) !important;
    background: rgb(32, 33, 37) !important;
}

body.dark-mode .drop-zone.drag-over {
    border: 2px dashed rgba(203, 213, 225, 0.8) !important;
    background: rgba(148, 163, 184, 0.05) !important;
}

body.dark-mode .drop-zone-text,
body.dark-mode .drop-zone-file-info {
    color: #f1f5f9;
}

body.dark-mode .translation-modal-container {
    background: rgb(32, 33, 37);
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    border: none;
}

body.dark-mode .modal-close-btn {
    background: transparent;
    color: #ffffff;
    border: none;
}

body.dark-mode .modal-close-btn:hover {
    background: transparent;
    color: #ffffff;
    transform: none;
}

body.dark-mode .video-container {
    background: #000;
    border: none;
}

body.dark-mode .language-chip {
    background: rgba(33, 150, 243, 0.4) !important;
    border: 1px solid rgba(33, 150, 243, 0.8) !important;
    color: #BBDEFB !important;
}

body.dark-mode .language-chip.original-language-chip {
    background: #223862 !important;
    border: 1px solid #475569 !important;
    color: #f1f5f9 !important;
}

body.dark-mode .language-chip .chip-credit {
    color: #ffffff !important;
}

body.dark-mode .add-language-chip {
    background: transparent !important;
    border: 2px dashed rgba(33, 150, 243, 0.7) !important;
    color: #90CAF9 !important;
}

body.dark-mode .target-language-chips .language-chip:hover {
    transform: none !important;
    background: rgba(255, 0, 0, 0.1) !important;
    border-color: rgba(255, 0, 0, 0.3) !important;
}

body.dark-mode .target-language-chips .language-chip .credit-icon,
body.dark-mode .target-language-chips .language-chip img.credit-icon {
    filter: none !important;
}

body.dark-mode .add-language-chip:hover {
    background: rgba(33, 150, 243, 0.15) !important;
    border-color: rgba(33, 150, 243, 1) !important;
    color: #BBDEFB !important;
}

body.dark-mode .language-option-card {
    background: #2A3442;
    border-color: #475569;
    color: #f1f5f9;
}

body.dark-mode .language-option-card:hover {
    border-color: #3b82f6;
    background: #1e3a5f;
    transform: none !important;
}

body.dark-mode .language-option-card.selected {
    border-color: #3b82f6;
    background: #1e3a5f;
}

body.dark-mode .language-option-card .language-name {
    color: #f1f5f9;
}

body.dark-mode .language-option-card {
    overflow: visible;
}

body.dark-mode .language-option-card .remove-btn {
    position: absolute;
    top: -10px;
    right: -10px;
    width: 22px;
    height: 22px;
    border: 1px solid rgba(255, 255, 255, 0.3);
    background: #000000;
    color: #ffffff;
    display: flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
    text-align: center;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

body.dark-mode .language-option-card .remove-btn i {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    line-height: 1;
    margin: 0;
    padding: 0;
    transform: translateX(0.5px);
}

body.dark-mode .language-option-card .remove-btn:hover {
    background: #000000;
    border-color: rgba(59, 130, 246, 0.5);
    color: #3b82f6;
}

body.dark-mode .language-option-card .language-credit span {
    color: #ffffff !important;
}

body.dark-mode .credit-charge-package-card {
    background: rgba(30, 30, 46, 0.9) !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
}

body.dark-mode .credit-charge-package-card:hover {
    border-color: rgba(255, 255, 255, 0.45) !important;
}

body.dark-mode .credit-charge-package-card.selected {
    border: 2px solid #3b82f6 !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2) !important;
    background: rgba(30, 30, 46, 0.9) !important;
}

body.dark-mode .credit-charge-package-card.popular.selected {
    border: 2px solid #3b82f6 !important;
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.2) !important;
    background: rgba(30, 30, 46, 0.9) !important;
}

body.dark-mode .credit-package-icon {
    background: rgba(255, 255, 255, 0.15) !important;
}

body.dark-mode .credit-charge-package-card.popular .credit-package-icon {
    background: rgba(255, 127, 80, 0.3) !important;
}

body.dark-mode .credit-package-description {
    color: rgba(255, 255, 255, 0.65) !important;
}

body.dark-mode .credit-package-description .credit-duration-number {
    color: #E3E3E3 !important;
}

body.dark-mode .credit-package-amount {
    color: #E3E3E3 !important;
}

body.dark-mode .credit-package-price-row {
    color: #f1f5f9;
}

body.dark-mode .credit-package-original-price {
    color: #6B7280;
    text-decoration-color: #EF4444 !important;
    text-decoration-thickness: 2px !important;
}

body.dark-mode .credit-package-discounted-price {
    color: #3b82f6;
}

body.dark-mode .credit-summary-card {
    background: rgb(32, 33, 37);
    border: 1px solid #4a4a4a;
}

body.dark-mode .credit-summary-title {
    color: #f1f5f9;
}

body.dark-mode .point-info-section {
    border-bottom: 1px solid #aaaaaa;
}

body.dark-mode .point-info-label {
    color: #E3E3E3;
}

body.dark-mode .point-info-value {
    color: #E3E3E3;
}

body.dark-mode .point-remaining {
    color: #10b981 !important;
}

body.dark-mode .point-remaining.negative {
    color: #ef4444 !important;
}

body.dark-mode .point-remaining.negative span {
    color: #ef4444 !important;
}

body.dark-mode .point-deducted {
    color: #ef4444 !important;
}

body.dark-mode .generate-subtitle-btn:enabled {
    background: #1E3A8A;
}

body.dark-mode .generate-subtitle-btn:enabled:hover {
    background: #1e40af;
}

body.dark-mode .translate-btn-progress {
    background: rgba(30, 58, 138, 0.15);
    border-color: rgba(30, 58, 138, 0.3);
}

body.dark-mode .translate-btn-progress-text {
    color: #f1f5f9;
}

body.dark-mode .credit-charge-modal-content {
    background: #1f2937 !important;
    border: 1px solid #E3E3E3 !important;
}

body.dark-mode .credit-charge-modal-header {
    border-bottom: 1px solid #E3E3E3 !important;
    background: rgba(31, 41, 55, 1) !important;
}

body.dark-mode .credit-charge-modal-header h3 {
    color: #f9fafb !important;
}

body.dark-mode .credit-charge-modal-close {
    background: transparent !important;
    color: #9ca3af !important;
}

body.dark-mode .credit-charge-modal-close:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #f9fafb !important;
}

body.dark-mode .language-modal .modal-content {
    background: rgb(42, 42, 45) !important;
    border: none !important;
}

body.dark-mode .language-modal .modal-header {
    background: rgb(42, 42, 45) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
}

body.dark-mode .language-modal .modal-header h3 {
    color: #f1f5f9 !important;
}

body.dark-mode .language-modal .modal-header-subtitle {
    color: #94a3b8 !important;
}

body.dark-mode .language-modal .modal-close {
    background: transparent !important;
    color: #f1f5f9 !important;
}

body.dark-mode .language-modal .modal-close:hover {
    background: transparent !important;
    color: #f1f5f9 !important;
}

body.dark-mode .language-modal .modal-body {
    background: rgb(42, 42, 45) !important;
}

body.dark-mode .modal-language-item {
    background: rgba(255, 255, 255, 0.08) !important;
    color: #e5e7eb !important;
    border: 1.5px solid rgba(255, 255, 255, 0.15) !important;
}

body.dark-mode .modal-language-item:hover {
    background: rgba(255, 255, 255, 0.12) !important;
    border-color: #60a5fa !important;
    color: #60a5fa !important;
    transform: none !important;
}

body.dark-mode .modal-language-item.selected {
    background: #1e40af !important;
    border-color: #2563eb !important;
    color: #ffffff !important;
}

body.dark-mode .payment-modal {
    background: rgba(30, 30, 30, 0.95) !important;
    border: 1px solid #E3E3E3;
}

body.dark-mode .payment-methods-container {
    background: #1e293b !important;
    border-right-color: #E3E3E3 !important;
}

body.dark-mode .payment-main-title {
    color: #f1f5f9 !important;
}

body.dark-mode .payment-method-btn {
    background: rgba(30, 30, 30, 0.95) !important;
    border-color: #E3E3E3 !important;
    color: #E3E3E3 !important;
}

body.dark-mode .payment-method-btn:hover {
    border-color: #3b82f6 !important;
    background: rgba(59, 130, 246, 0.1) !important;
}

body.dark-mode .payment-method-btn.active {
    border: 1px solid #2a2a2a !important;
    background: #252525 !important;
    box-shadow: none !important;
}

body.dark-mode .payment-method-btn.active:hover {
    border: 1px solid #2a2a2a !important;
    background: #252525 !important;
    box-shadow: none !important;
}

body.dark-mode .payment-method-btn span {
    color: #f1f5f9 !important;
}

body.dark-mode .payment-method-description {
    color: #94a3b8 !important;
}

body.dark-mode .payment-method-credit-amount {
    color: #ffffff !important;
}

body.dark-mode .payment-method-credit-label {
    color: #ffffff !important;
}

body.dark-mode .payment-method-btn.active .payment-method-credit-amount {
    color: #ffffff !important;
}

body.dark-mode .payment-method-price-unit {
    color: #ffffff !important;
}

body.dark-mode .payment-method-original-price {
    color: #6b7280 !important;
}

body.dark-mode .payment-method-discounted-price {
    color: #ffffff !important;
}

body.dark-mode .payment-method-btn.active .payment-method-discounted-price {
    color: #ffffff !important;
}

body.dark-mode .payment-more-link {
    color: #94a3b8 !important;
}

body.dark-mode .payment-more-link:hover {
    color: #f1f5f9 !important;
}

body.dark-mode .payment-summary-container {
    background: rgba(30, 30, 30, 0.7) !important;
}

body.dark-mode .payment-summary-label {
    color: #94a3b8 !important;
}

body.dark-mode .payment-summary-value {
    color: #f1f5f9 !important;
}

body.dark-mode .payment-modal-body .terms-box {
    background: #1C2530 !important;
    border-color: rgba(255, 255, 255, 0.1) !important;
    color: #FFFFFF !important;
}

body.dark-mode .payment-modal-body .terms-box strong {
    color: #FFFFFF !important;
}

body.dark-mode .payment-modal-body .payment-submit-btn {
    background: #1C2530 !important;
    color: #FFFFFF !important;
}

body.dark-mode .payment-modal-body .payment-submit-btn:hover {
    background: rgb(28, 37, 48) !important;
    color: #FFFFFF !important;
    opacity: 0.9;
}

body.dark-mode .payment-success-modal {
    background: #1f2937;
    border: 1px solid rgba(255, 255, 255, 0.1);
}

body.dark-mode .payment-success-content h2 {
    color: #f9fafb;
}

body.dark-mode .payment-success-info {
    background: rgba(255, 255, 255, 0.05);
}

body.dark-mode .success-info-label {
    color: #94a3b8;
}

body.dark-mode .success-info-value {
    color: #f1f5f9;
}

/* 반응형 디자인 */
@media (max-width: 1200px) {
    .translation-layout {
        grid-template-columns: 1fr;
        gap: 24px;
    }
    
    .credit-summary-column {
        order: -1;
    }
}

@media (max-width: 768px) {
    .main-container {
        padding: 20px 15px;
    }
    
    .upload-section-header {
        margin-bottom: 20px;
    }
    
    .upload-title {
        font-size: 1.5rem;
    }
    
    .upload-subtitle {
        font-size: 0.95rem;
    }
    
    .drop-zone {
        min-height: 400px;
        padding: 30px 20px;
        border-radius: 20px;
    }
    
    .upload-icon-wrapper {
        width: 80px;
        height: 80px;
    }
    
    .upload-icon {
        width: 50px;
        height: 50px;
    }
    
    .drop-zone-text {
        font-size: 1.3rem;
    }
    
    .drop-zone-file-info {
        font-size: 1rem;
    }
    
    .translation-modal-container {
        padding: 24px;
        max-height: 95vh;
    }
    
    .translation-layout {
        gap: 20px;
    }
    
    .target-language-chips {
        flex-wrap: wrap;
    }
    
    .payment-modal-body {
        flex-direction: column;
    }

    .payment-methods-container {
        border-right: none;
    }

    .payment-summary-container {
        width: 100%;
    }

    .payment-modal {
        margin: 10px;
        height: calc(100vh - 20px);
        max-height: calc(100vh - 20px);
    }
    
    .language-grid {
        grid-template-columns: repeat(auto-fill, minmax(120px, 1fr));
        gap: 6px;
    }
    
    .modal-language-item {
        padding: 10px 12px;
        font-size: 13px;
    }
}

@media (max-width: 480px) {
    .main-container {
        padding: 15px 10px;
    }
    
    .upload-title {
        font-size: 1.3rem;
    }
    
    .upload-subtitle {
        font-size: 0.85rem;
    }
    
    .drop-zone {
        min-height: 350px;
        padding: 25px 15px;
    }
    
    .upload-icon-wrapper {
        width: 70px;
        height: 70px;
    }
    
    .upload-icon {
        width: 40px;
        height: 40px;
    }
    
    .drop-zone-text {
        font-size: 0.95rem;
    }
    
    .drop-zone-file-info {
        font-size: 0.95rem;
    }
}

/* 사용자 드롭다운 메뉴 위치 조정 - cc.jsp 참고 */
.lx_app_wrap {
    overflow: visible !important; /* 드롭다운이 잘리지 않도록 */
}

.lx_app_header {
    overflow: visible !important; /* 드롭다운이 잘리지 않도록 */
}

.lx_app_header.sticky {
    position: sticky !important;
    top: 0 !important;
    z-index: 1000 !important; /* 헤더 자체의 z-index */
}

.user-info-area {
    position: relative !important;
}

.user-dropdown-menu {
    position: absolute !important;
    top: calc(100% + 8px) !important;
    right: 130px !important; /* cc.jsp와 동일한 위치 */
    z-index: 1001 !important; /* polytalk.css와 동일 */
}

.user-dropdown-menu.show {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
    z-index: 1001 !important; /* 표시될 때도 z-index 유지 */
}

/* 메가 메뉴 스타일 보장 - mega-menu.css 참고 */
.more-menu-btn {
    position: relative;
}

.more-menu-dropdown {
    position: fixed;
    z-index: 1001; /* mega-menu.css와 동일 */
    /* top과 right는 JavaScript에서 동적으로 계산되므로 CSS에서는 설정하지 않음 */
}

.more-menu-dropdown.active {
    opacity: 1 !important;
    visibility: visible !important;
    pointer-events: auto !important;
    transform: translate3d(0, 0, 0) scale(1) !important;
    z-index: 99999 !important; /* mega-menu.css와 동일 */
    position: fixed !important;
}

/* 헤더 요소들이 드롭다운을 가리지 않도록 */
.header-right {
    position: relative !important;
    overflow: visible !important;
}

.dark-mode-toggle-wrapper {
    position: relative !important;
    overflow: visible !important;
}

.user-info-area {
    position: relative !important;
    overflow: visible !important;
}

