        :root {
            --primary: #000000;
            --primary-hover: #1a1a1a;
            --secondary: #4f46e5;
            --background: #ffffff;
            --surface: #f8f9fa;
            --text-primary: #0f172a;
            --text-secondary: #64748b;
            --text-muted: #94a3b8;
            --border: #e2e8f0;
            --border-light: #f1f5f9;
            --white: #ffffff;
            --gray-50: #f8fafc;
            --gray-100: #f1f5f9;
            --gray-200: #e2e8f0;
            --gray-300: #cbd5e1;
            --gray-400: #94a3b8;
            --gray-500: #64748b;
            --gray-600: #475569;
            --gray-700: #334155;
            --gray-800: #1e293b;
            --gray-900: #0f172a;
            --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.05);
            --shadow: 0 1px 3px 0 rgba(0, 0, 0, 0.1), 0 1px 2px 0 rgba(0, 0, 0, 0.06);
            --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.1), 0 2px 4px -1px rgba(0, 0, 0, 0.06);
            --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.1), 0 4px 6px -2px rgba(0, 0, 0, 0.05);
            --shadow-xl: 0 20px 25px -5px rgba(0, 0, 0, 0.1), 0 10px 10px -5px rgba(0, 0, 0, 0.04);
            --error: #dc3545;
            --success: #28a745;
        }
        
        * {
            margin: 0;
            padding: 0;
            box-sizing: border-box;
        }
        
        html {
            width: 100%;
            overflow-x: hidden;
        }
        
        body {
            font-family: 'Inter', 'Noto Sans KR', sans-serif;
            background-color: var(--background);
            color: var(--text-primary);
            line-height: 1.6;
            min-height: 100vh;
            overflow-x: hidden;
            width: 100%;
            min-width: 0;
        }
        
        .container {
            max-width: 1280px;
            margin: 0 auto;
            padding: 0 20px;
            width: 100%;
            box-sizing: border-box;
        }
        
        nav {
            background-color: var(--white);
            border-bottom: none;
            position: fixed;
            width: calc(100% - 96px);
            left: 48px;
            right: 48px;
            margin: 0 auto;
            top: 1.8em;
            z-index: 1000;
            transition: all 0.3s ease;
        }

        nav.scrolled {
            box-shadow: 0 4px 24px 0 rgba(0,0,0,0.10);
            border-radius:12px;
            background: #fff;
        }
        
        .nav-container {
            display: flex;
            justify-content: space-between;
            align-items: center;
            padding: 1rem 0;
        }
        
        .logo {
            font-size: 24px;
            font-weight: 700;
            color: var(--primary);
            text-decoration: none;
            display: flex;
            align-items: center;
            gap: 0.5rem;
        }
        
        .logo svg {
            width: 32px;
            height: 32px;
        }
        
        .nav-links {
            display: flex;
            gap: 2rem;
            align-items: center;
        }
        
        .nav-links a {
            color: var(--text-secondary);
            text-decoration: none;
            font-weight: 500;
            transition: color 0.3s ease;
        }
        
        .nav-links a:hover {
            color: var(--primary);
        }
        
        .nav-button {
            background-color: transparent;
            color: var(--primary);
            padding: 0.5rem 1rem;
            border: 2px solid var(--border);
            border-radius: 8px;
            text-decoration: none;
            font-weight: 600;
            transition: all 0.3s ease;
            display: inline-block;
        }
        
        .nav-button:hover {
            background-color: var(--gray-50);
            border-color: var(--primary);
        }
        
        .user-info {
            background-color: var(--gray-100);
            border-radius: 8px;
            padding: 0.75rem 1rem;
            margin-right: 1rem;
            font-size: 0.875rem;
            color: var(--text-secondary);
            display: none;
            align-items: center;
            gap: 0.5rem;
            max-width: 60vw;
            white-space: normal; /* 줄바꿈 허용 */
            word-break: break-word; /* 긴 이메일 등 강제 줄바꿈 */
            line-height: 1.3;
        }
        
        .user-avatar {
            width: 24px;
            height: 24px;
            border-radius: 50%;
            background-color: var(--primary);
            display: flex;
            align-items: center;
            justify-content: center;
            color: white;
            font-size: 12px;
            font-weight: 600;
        }
        
        .main-content {
            margin-top: 0;
            padding: 120px 0 40px 0;
            min-height: calc(100vh - 80px);
        }
        
        .translate-container {
            padding: 0;
            margin-bottom: 2rem;
            display: flex;
            gap: 2rem;
            align-items: flex-start;
            width: 100%;
        }

        .pdf-preview-section {
            flex: 0 0 calc(50% - 1rem);
            width: calc(50% - 1rem);
            background-color: var(--white);
            border-radius: 16px;
            padding: 1.5rem;
            box-shadow: var(--shadow-md);
            border: 1px solid var(--border);
        }

        .pdf-preview-header {
            display: flex;
            align-items: center;
            gap: 0.75rem;
            margin-bottom: 1rem;
            padding-bottom: 0.75rem;
            border-bottom: 1px solid var(--border-light);
        }

        .pdf-preview-header h3 {
            font-size: 1.125rem;
            font-weight: 600;
            color: var(--text-primary);
        }

        .pdf-preview-container {
            position: relative;
            background-color: var(--gray-50);
            border-radius: 8px;
            width: 100%;
            aspect-ratio: 1 / 1.414; /* A4 비율 */
            display: flex;
            align-items: center;
            justify-content: center;
            overflow: hidden;
        }

        /* 스크롤 모드: 여러 페이지 세로 스크롤 */
        .pdf-preview-container.scroll-mode {
            aspect-ratio: auto;
            overflow-y: auto;
            max-height: 70vh;
            align-items: flex-start;
            justify-content: flex-start;
            padding: 1rem;
        }

        .pdf-pages {
            width: 100%;
        }

        .pdf-page-canvas {
            display: block;
            width: 100%;
            margin: 0 auto 1rem;
            box-shadow: var(--shadow-sm);
            border-radius: 4px;
        }

        .pdf-preview-placeholder {
            text-align: center;
            color: var(--text-muted);
            padding: 2rem;
        }

        .pdf-preview-placeholder .icon {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            margin-bottom: 1rem;
        }

        .pdf-preview-placeholder .icon svg {
            width: 64px;
            height: 64px;
            color: var(--gray-200); /* 업로드 이모티콘 배지 배경색과 동일 */
        }

        .pdf-canvas {
            max-width: 100%;
            max-height: 100%;
            box-shadow: var(--shadow-sm);
            border-radius: 4px;
            object-fit: contain;
        }

        .pdf-controls {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 1rem;
            margin-top: 1rem;
        }

        .pdf-control-btn {
            background: var(--white);
            border: 1px solid var(--border);
            border-radius: 6px;
            padding: 0.5rem 1rem;
            cursor: pointer;
            transition: all 0.2s ease;
            font-size: 0.875rem;
        }

        .pdf-control-btn:hover {
            background: var(--gray-50);
        }

        .pdf-control-btn:disabled {
            opacity: 0.5;
            cursor: not-allowed;
        }

        .page-info {
            font-size: 0.875rem;
            color: var(--text-secondary);
        }

        .pdf-upload-section {
            flex: 0 0 calc(50% - 1rem);
            width: calc(50% - 1rem);
        }
        
        .translate-header {
            text-align: center;
            margin-bottom: 3rem;
            max-width: 1280px;
            margin: 0 auto 3rem auto;
            padding: 0 20px;
        }
        
        .translate-header h1 {
            font-size: 2.5rem;
            font-weight: 700;
            margin-top: 0;
            margin-bottom: 1rem;
            color: var(--text-primary);
        }
        
        .translate-header p {
            font-size: 1.125rem;
            color: var(--text-secondary);
        }

        /* 상시 공지 패널 (헤더 우측 여백) */
        .main-content > .container {
            position: relative;
        }

        .notice-panel {
            display: none;
            position: absolute;
            top: 1rem;
            right: 20px;
            width: 320px;
            background-color: var(--white);
            border: 1px solid var(--border);
            border-radius: 16px;
            box-shadow: var(--shadow-md);
            padding: 0.75rem 1rem;
            z-index: 50;
            max-height: 120px;
            overflow: hidden;
            transition: max-height 0.35s cubic-bezier(0.16, 1, 0.3, 1), box-shadow 0.25s ease;
        }

        .notice-panel.visible {
            display: block;
        }

        .notice-panel.expanded {
            max-height: 420px;
            box-shadow: var(--shadow-lg);
        }

        .notice-panel-header {
            display: flex;
            align-items: center;
            gap: 0.375rem;
            margin-bottom: 0.375rem;
        }

        .notice-panel-header svg {
            width: 16px;
            height: 16px;
            color: var(--secondary);
            flex-shrink: 0;
        }

        .notice-panel-title {
            font-size: 0.8125rem;
            font-weight: 600;
            color: var(--text-secondary);
            flex: 1;
        }

        .notice-close-btn {
            display: none;
            background: none;
            border: none;
            padding: 2px;
            cursor: pointer;
            color: var(--text-muted);
            line-height: 0;
        }

        .notice-close-btn:hover {
            color: var(--text-primary);
        }

        .notice-panel.expanded .notice-close-btn {
            display: block;
        }

        .notice-list {
            transition: opacity 0.2s ease;
            max-height: 67px;
            overflow-y: auto;
            scrollbar-gutter: stable;
        }

        .notice-list::-webkit-scrollbar {
            width: 6px;
        }

        .notice-list::-webkit-scrollbar-thumb {
            background: #cbd5e1;
            border-radius: 3px;
        }

        .notice-row {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            padding: 0.375rem 0.25rem;
            border-radius: 8px;
            cursor: pointer;
            transition: background-color 0.15s ease;
            width: 100%;
            border: none;
            background: none;
            color: inherit;
            font: inherit;
            text-align: left;
        }

        .notice-row:hover {
            background-color: var(--gray-50);
        }

        .notice-row:focus-visible {
            outline: 2px solid var(--secondary);
            outline-offset: -2px;
        }

        .notice-row .announcement-badge {
            flex-shrink: 0;
            font-size: 0.625rem;
            padding: 0.125rem 0.5rem;
        }

        .notice-row-title {
            flex: 1;
            min-width: 0;
            font-size: 0.8125rem;
            color: var(--text-primary);
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
        }

        .notice-unread-dot {
            width: 6px;
            height: 6px;
            border-radius: 50%;
            background-color: var(--error);
            flex-shrink: 0;
        }

        .notice-detail {
            display: none;
            opacity: 0;
            transform: translateX(12px);
            transition: opacity 0.25s ease, transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
        }

        .notice-detail-title {
            font-size: 0.9375rem;
            font-weight: 700;
            color: var(--text-primary);
            margin: 0.25rem 0 0.5rem;
            line-height: 1.4;
        }

        .notice-detail-body {
            font-size: 0.8125rem;
            color: var(--text-secondary);
            line-height: 1.65;
            max-height: 280px;
            overflow-y: auto;
        }

        .notice-detail-body::-webkit-scrollbar {
            width: 6px;
        }

        .notice-detail-body::-webkit-scrollbar-thumb {
            background: #cbd5e1;
            border-radius: 3px;
        }

        .notice-back-btn {
            display: inline-flex;
            align-items: center;
            gap: 0.25rem;
            background: none;
            border: none;
            padding: 0;
            font-size: 0.75rem;
            font-weight: 600;
            color: var(--text-secondary);
            cursor: pointer;
        }

        .notice-back-btn:hover {
            color: var(--text-primary);
        }

        /* 공지 로딩 스켈레톤 */
        .notice-skeleton-row {
            display: flex;
            align-items: center;
            gap: 0.5rem;
            padding: 0.25rem 0.25rem;
        }

        .notice-skeleton-bar {
            height: 10px;
            border-radius: 5px;
            background: linear-gradient(90deg, #f1f5f9 25%, #e2e8f0 37%, #f1f5f9 63%);
            background-size: 400% 100%;
            animation: noticeSkeletonShimmer 1.4s ease infinite;
        }

        .notice-skeleton-bar.badge {
            width: 34px;
            height: 14px;
            border-radius: 999px;
            flex-shrink: 0;
        }

        @keyframes noticeSkeletonShimmer {
            0% { background-position: 100% 50%; }
            100% { background-position: 0 50%; }
        }

        @media (prefers-reduced-motion: reduce) {
            .notice-skeleton-bar {
                animation: none;
            }
        }

        /* 좁은 화면: 부제목과 겹치기 전에 헤더 아래 전체 너비 바로 전환 */
        @media (max-width: 1140px) {
            .notice-panel {
                position: static;
                width: 100%;
                margin: -1.5rem auto 2rem;
            }
        }

        .upload-area {
            border: 2.4px dashed #cbd5e1; /* 기본 색상을 살짝 더 진하게 */
            border-radius: 16px;
            padding: 2rem 1.5rem 0; /* 하단 패딩 제거 */
            text-align: center;
            background-color: transparent; /* 점선 영역 내부 색 제거 */
            transition: all 0.3s ease;
            cursor: pointer;
            margin-bottom: 0;
        }
        
        .upload-area:hover {
            border-color: var(--primary);
            background-color: transparent;
        }
        
        .upload-area.dragging {
            border-color: var(--primary);
            background-color: transparent;
            transform: scale(1.02);
        }
        
        .upload-icon {
            width: 64px; /* 배지 지름 축소 */
            height: 64px;
            margin: 0 auto 0.8rem; /* 텍스트를 살짝 위로 */
            background-color: var(--gray-50); /* 기본 배경으로 복원 */
            border-radius: 50%;
            display: flex;
            align-items: center;
            justify-content: center;
            color: var(--gray-500);
        }

        .upload-icon svg {
            width: 40px; /* 아이콘 크기 확대 */
            height: 40px;
            color: inherit;
        }
        
        .upload-area h3 {
            font-size: 1.1rem;
            font-weight: 500;
            margin-bottom: 0.5rem;
            color: var(--text-primary);
        }
        
        .upload-area p {
            color: var(--text-secondary);
            margin-bottom: 1.5rem;
        }
        
        .file-input {
            display: none;
        }
        
        
        .file-info {
            display: none;
            background-color: rgba(15, 178, 111, 0.08); /* 연한 초록 배경 */
            border-radius: 12px;
            padding: 1.5rem;
            margin-top: 1.5rem;
            margin-bottom: 0;
            align-items: center;
            gap: 1rem;
            border: 1px solid var(--border);
        }
        
        .file-info.active {
            display: flex;
        }
        
        .file-icon {
            width: 48px;
            height: 48px;
            background-color: transparent; /* 배경 네모 제거 */
            border-radius: 8px;
            display: flex;
            align-items: center;
            justify-content: center;
            color: inherit;
            flex-shrink: 0;
        }

        .file-icon svg {
            width: 40px;
            height: 40px;
            display: block;
        }
        
        .file-details {
            flex: 1;
            min-width: 0;
        }
        
        .file-name {
            font-weight: 600;
            color: var(--text-primary);
            margin-bottom: 0.25rem;
            overflow: hidden;
            text-overflow: ellipsis;
            white-space: nowrap;
            max-width: 100%;
        }
        
        .file-size {
            font-size: 0.875rem;
            color: var(--text-secondary);
        }
        
        .remove-file {
            background-color: var(--error);
            color: var(--white);
            padding: 0.5rem 1rem;
            border-radius: 6px;
            border: none;
            font-weight: 500;
            cursor: pointer;
            transition: opacity 0.3s ease;
            flex-shrink: 0;
        }
        
        .remove-file:hover {
            opacity: 0.9;
        }
        
        .options-section {
            display: grid;
            grid-template-columns: 1fr 1fr; /* 두 개의 긴 가로 셀 */
            gap: 2rem;
            margin-bottom: 0; /* 하단 여백 제거 */
            align-items: end;
        }

        /* 번역 설정 섹션의 내부 여백을 살짝 줄여 전체 공간 압축 */
        .settings-section {
            padding-bottom: 0.5rem;
        }
        
        .option-group {
            background-color: transparent; /* 박스 제거 */
            padding: 0; /* 내부 여백 제거 */
            border-radius: 0;
            border: none; /* 테두리 제거 */
        }
        
        .option-label {
            font-weight: 700;
            color: var(--text-primary);
            margin-bottom: 0.5rem;
            display: block;
        }
        
        .select-wrapper {
            position: relative;
            margin-top: 0.8rem; /* 선택 박스만 조금 아래로 내림 */
            margin-bottom: 0; /* 아래 여백 축소 */
        }
        
        select {
            width: 100%;
            padding: 0.75rem 1rem; /* 세로로 얇게 */
            border: 1px solid var(--border); /* 섹션 테두리와 동일 굵기 */
            border-radius: 16px; /* 섹션 라운드와 어울리게 */
            background-color: var(--white);
            font-size: 1rem;
            color: var(--text-primary);
            cursor: pointer;
            appearance: none;
            transition: border-color 0.2s ease, box-shadow 0.2s ease;
            box-shadow: var(--shadow-md); /* 섹션과 통일감 */
        }
        
        select:hover {
            border-color: var(--primary);
        }
        
        select:focus {
            outline: none;
            border-color: var(--primary);
        }
        
        .select-wrapper::after {
            content: "\25BE";
            position: absolute;
            right: 1rem;
            top: 50%;
            transform: translateY(-50%);
            pointer-events: none;
            color: var(--text-secondary);
            font-size: 0.875rem;
        }

        .model-tier-group {
            margin-top: 1.2rem;
        }

        .tier-toggle {
            display: grid;
            grid-template-columns: 1fr 1fr;
            gap: 4px;
            padding: 4px;
            margin-top: 0.8rem; /* select-wrapper와 동일한 라벨 간격 */
            border: 1px solid var(--border);
            border-radius: 16px; /* select와 동일한 곡률 */
            background-color: var(--white);
            box-shadow: var(--shadow-md);
        }

        .tier-option input {
            position: absolute;
            opacity: 0;
            pointer-events: none;
        }

        .tier-label-text {
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.375rem;
            padding: 0.6rem 1rem;
            border-radius: 12px;
            font-size: 0.95rem;
            font-weight: 600;
            color: var(--text-secondary);
            cursor: pointer;
            transition: all 0.2s ease;
        }

        .tier-option input:checked + .tier-label-text {
            background-color: var(--secondary);
            color: var(--white);
        }

        .tier-option input:focus-visible + .tier-label-text {
            outline: 2px solid var(--secondary);
            outline-offset: 2px;
        }

        .tier-option input:disabled + .tier-label-text {
            cursor: not-allowed;
            opacity: 0.55;
        }

        .tier-badge {
            font-size: 0.7rem;
            font-weight: 700;
            padding: 0.1rem 0.4rem;
            border-radius: 999px;
            background-color: var(--border-light);
            color: var(--text-secondary);
        }

        .tier-option input:checked + .tier-label-text .tier-badge {
            background-color: rgba(255, 255, 255, 0.25);
            color: var(--white);
        }

        .tier-caption {
            margin-top: 0.5rem;
            font-size: 0.8rem;
            color: var(--text-secondary);
        }

        .translate-button {
            width: 100%;
            background-color: var(--secondary);
            color: var(--white);
            padding: 1rem 2rem;
            border-radius: 16px; /* select와 동일한 곡률 */
            border: none;
            font-size: 18px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            display: flex;
            align-items: center;
            justify-content: center;
            gap: 0.5rem;
        }
        
        .translate-button:hover:not(:disabled) {
            background-color: #0fb26f;
            transform: translateY(-2px);
            box-shadow: var(--shadow-lg);
        }
        
        .translate-button:disabled {
            background-color: var(--gray-400);
            cursor: not-allowed;
        }
        
        .translate-button:disabled span {
            animation: pulse 1.5s infinite;
        }
        
        @keyframes pulse {
            0% { opacity: 1; }
            50% { opacity: 0.6; }
            100% { opacity: 1; }
        }
        
        .progress-section {
            display: none;
            background-color: var(--background);
            border-radius: 16px;
            padding: 1.75rem;
            margin-top: 2rem;
            margin-bottom: 1rem;
            border: 1px solid var(--border-light);
            box-shadow: var(--shadow-md);
        }

        .progress-section.active {
            display: block;
            animation: progressCardIn 0.3s ease;
        }

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

        .progress-card-header {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 0.75rem;
            margin-bottom: 0.375rem;
        }

        .progress-title {
            display: inline-flex;
            align-items: center;
            font-size: 1.125rem;
            font-weight: 600;
            color: var(--text-primary);
        }

        .progress-title-dots {
            display: inline-flex;
            gap: 3px;
            margin-left: 6px;
        }

        .progress-title-dots i {
            width: 4px;
            height: 4px;
            border-radius: 50%;
            background-color: var(--secondary);
            animation: progressDot 1.4s infinite ease-in-out;
        }

        .progress-title-dots i:nth-child(2) { animation-delay: 0.2s; }
        .progress-title-dots i:nth-child(3) { animation-delay: 0.4s; }

        @keyframes progressDot {
            0%, 60%, 100% { opacity: 0.25; }
            30% { opacity: 1; }
        }

        .progress-elapsed {
            display: inline-flex;
            align-items: center;
            gap: 0.375rem;
            background-color: var(--gray-100);
            color: var(--text-secondary);
            border-radius: 999px;
            padding: 0.25rem 0.75rem;
            font-size: 0.875rem;
            font-weight: 500;
            font-variant-numeric: tabular-nums;
            white-space: nowrap;
        }

        .progress-status {
            color: var(--text-secondary);
            font-size: 0.9375rem;
            margin-bottom: 1.25rem;
        }

        .progress-bar {
            width: 100%;
            height: 10px;
            background-color: var(--gray-200);
            border-radius: 999px;
            overflow: hidden;
            margin-bottom: 0.875rem;
        }

        .progress-fill {
            position: relative;
            height: 100%;
            border-radius: 999px;
            background: linear-gradient(90deg, #4f46e5, #6366f1);
            width: 0%;
            transition: width 0.8s cubic-bezier(0.4, 0, 0.2, 1);
            overflow: hidden;
        }

        /* 채움 위를 상시 흐르는 광택 — 값이 멈춰 있어도 살아있음을 표시 */
        .progress-fill::after {
            content: '';
            position: absolute;
            inset: 0;
            background: linear-gradient(105deg, transparent 30%, rgba(255, 255, 255, 0.35) 50%, transparent 70%);
            transform: translateX(-100%);
            animation: progressSheen 2.4s infinite;
        }

        @keyframes progressSheen {
            to { transform: translateX(100%); }
        }

        /* 부정형: 실제 %가 없는 구간 — 세그먼트가 좌→우로 흐름 */
        .progress-section.indeterminate .progress-fill {
            width: 32%;
            transition: none;
            animation: progressSlide 1.4s infinite cubic-bezier(0.45, 0, 0.55, 1);
        }

        @keyframes progressSlide {
            0% { margin-left: -32%; }
            100% { margin-left: 100%; }
        }

        /* 완료: 다운로드 배너와 동일한 에메랄드 그린 */
        .progress-section.complete .progress-fill {
            background: linear-gradient(135deg, #10b981, #0fb26f);
            box-shadow: 0 2px 8px rgba(15, 178, 111, 0.3);
        }

        .progress-section.complete .progress-percentage { color: #0fb26f; }
        .progress-section.complete .progress-title-dots { display: none; }

        .progress-meta {
            display: flex;
            align-items: center;
            justify-content: space-between;
            gap: 0.75rem;
            min-height: 1.75rem;
        }

        .progress-pages {
            display: inline-flex;
            align-items: center;
            background-color: var(--gray-100);
            color: var(--secondary);
            border-radius: 999px;
            padding: 0.25rem 0.75rem;
            font-size: 0.875rem;
            font-weight: 600;
            font-variant-numeric: tabular-nums;
            white-space: nowrap;
        }

        .progress-percentage {
            font-size: 1.5rem;
            font-weight: 700;
            color: var(--secondary);
            font-variant-numeric: tabular-nums;
            margin-left: auto;
        }

        .progress-footer {
            display: flex;
            align-items: flex-end;
            justify-content: space-between;
            gap: 1rem;
            margin-top: 0.75rem;
        }

        .progress-hint {
            color: var(--text-muted);
            font-size: 0.8125rem;
            opacity: 0;
            transition: opacity 0.6s ease;
        }

        .progress-hint.visible { opacity: 1; }

        .progress-cancel-btn {
            background: none;
            border: none;
            cursor: pointer;
            color: var(--text-muted);
            font-size: 0.8125rem;
            padding: 0.25rem 0.5rem;
            border-radius: 6px;
            margin-left: auto;
            flex-shrink: 0;
            transition: color 0.2s ease, background-color 0.2s ease;
        }

        .progress-cancel-btn:not(:disabled):hover {
            color: var(--error);
            background-color: var(--gray-100);
        }

        .progress-cancel-btn:disabled {
            cursor: not-allowed;
            opacity: 0.55;
        }

        @media (prefers-reduced-motion: reduce) {
            .progress-section.active { animation: none; }
            .progress-fill { transition-duration: 0.2s; }
            .progress-fill::after,
            .progress-title-dots i { animation: none; }
            .progress-section.indeterminate .progress-fill {
                width: 100%;
                margin-left: 0;
                animation: pulse 1.5s infinite;
            }
        }
        
        .flash-messages {
            position: fixed;
            top: 1.2rem;
            left: 50%;
            transform: translateX(-50%);
            z-index: 2001;
            margin-bottom: 2rem;
            width: auto;
            max-width: 90vw;
        }
        
        .flash-message {
            padding: 0.5rem 1rem;
            border-radius: 8px;
            margin-bottom: 1rem;
            display: flex;
            align-items: center;
            gap: 0.75rem;
            animation: slideIn 0.3s ease;
            background-color: #f5f5f5;
        }
        
        /* 한도 초과 모달 버튼 개별 스타일 */
        #limitWaitBtn {
            background: #ffffff;
            color: #000000;
            border: 1.5px solid #000000;
        }
        #limitWaitBtn:hover {
            background: var(--gray-50);
            border-color: #000000;
            color: #000000;
        }
        #limitUpgradeBtn {
            background: #ffd93d; /* 노란색 배경 */
            color: #000000;      /* 검정 글자 */
            border: 1.5px solid #000000;
        }
        #limitUpgradeBtn:hover {
            background: #ffd93d; /* 호버 시에도 노란색 유지 */
            filter: brightness(0.98);
            color: #000000;      /* 호버 시에도 검정 글자 유지 */
            border-color: #000000;
        }

        /* 공지사항 전용 모달 (미니멀 화이트) */
        .announcement-overlay {
            position: fixed;
            inset: 0;
            background-color: rgba(15, 23, 42, 0.45);
            backdrop-filter: blur(4px);
            -webkit-backdrop-filter: blur(4px);
            z-index: 2999;
            display: none;
        }

        .announcement-overlay.show {
            display: block;
            animation: announcementFadeIn 0.25s ease;
        }

        .announcement-modal {
            position: fixed;
            top: 50%;
            left: 50%;
            transform: translate(-50%, -50%);
            background-color: white;
            border: 1px solid #e2e8f0;
            border-radius: 20px;
            box-shadow: 0 24px 48px -12px rgba(15, 23, 42, 0.18), 0 4px 12px rgba(15, 23, 42, 0.06);
            padding: 2rem;
            max-width: 480px;
            width: calc(100vw - 2rem);
            max-height: calc(100vh - 4rem);
            display: none;
            flex-direction: column;
            z-index: 3000;
        }

        .announcement-modal.show {
            display: flex;
            animation: announcementPopIn 0.25s cubic-bezier(0.16, 1, 0.3, 1);
        }

        .announcement-header {
            display: flex;
            flex-direction: column;
            align-items: flex-start;
            gap: 0.625rem;
            margin-bottom: 1rem;
        }

        .announcement-badge {
            display: inline-block;
            background-color: #f1f5f9;
            color: #475569;
            font-size: 0.6875rem;
            font-weight: 600;
            letter-spacing: 0.04em;
            padding: 0.25rem 0.625rem;
            border-radius: 999px;
        }

        .announcement-badge.error {
            background-color: #fef2f2;
            color: #dc2626;
        }

        .announcement-badge.promo {
            background-color: #fff7ed;
            color: #ea580c;
        }

        .announcement-title {
            font-size: 1.25rem;
            font-weight: 700;
            letter-spacing: -0.01em;
            color: var(--text-primary);
            margin: 0;
            line-height: 1.4;
        }

        .announcement-body {
            color: var(--text-secondary);
            font-size: 0.9rem;
            line-height: 1.65;
            overflow-y: auto;
            flex: 1;
            min-height: 0;
            margin-bottom: 1.5rem;
        }

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

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

        .announcement-body::-webkit-scrollbar-thumb {
            background: #cbd5e1;
            border-radius: 3px;
        }

        .announcement-confirm {
            background-color: var(--primary);
            color: white;
            border: none;
            padding: 0.875rem;
            border-radius: 10px;
            font-size: 0.9375rem;
            font-weight: 600;
            cursor: pointer;
            transition: background-color 0.2s ease;
            width: 100%;
            flex-shrink: 0;
        }

        .announcement-confirm:hover {
            background-color: var(--primary-hover);
        }

        @keyframes announcementFadeIn {
            from { opacity: 0; }
            to { opacity: 1; }
        }

        @keyframes announcementPopIn {
            from {
                opacity: 0;
                transform: translate(-50%, -50%) scale(0.96);
            }
            to {
                opacity: 1;
                transform: translate(-50%, -50%) scale(1);
            }
        }

        @media (max-width: 480px) {
            .announcement-modal {
                padding: 1.5rem 1.25rem;
                border-radius: 16px;
                max-height: calc(100vh - 3rem);
            }

            .announcement-title {
                font-size: 1.125rem;
            }
        }

        /* 할인 쿠폰 버튼 스타일 */
        .discount-button {
            position: absolute;
            right: 0;
            top: 50%;
            transform: translateY(-50%);
            background: linear-gradient(135deg, #ff6b6b, #ffd93d);
            color: white;
            border: none;
            padding: 0.4rem 0.8rem;
            border-radius: 6px;
            font-size: 0.75rem;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.2s ease;
            box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
            white-space: nowrap;
            animation: discountBreath 2.4s ease-in-out infinite;
        }

        @keyframes discountBreath {
            0%, 100% {
                transform: translateY(-50%) scale(1);
                box-shadow: 0 2px 8px rgba(255, 107, 107, 0.3);
            }
            50% {
                transform: translateY(-50%) scale(1.05);
                box-shadow: 0 3px 10px rgba(255, 107, 107, 0.4);
            }
        }

        @media (prefers-reduced-motion: reduce) {
            .discount-button {
                animation: none;
            }
        }

        .discount-button:hover {
            animation: none;
            transform: translateY(-50%) scale(1.15);
            box-shadow: 0 4px 12px rgba(255, 107, 107, 0.4);
        }

        .discount-button:active {
            animation: none;
            transform: translateY(-50%) scale(0.95);
        }
        
        @keyframes slideIn {
            from {
                transform: translateY(-20px);
                opacity: 0;
            }
            to {
                transform: translateY(0);
                opacity: 1;
            }
        }
        @keyframes slideOutUp {
            from {
                transform: translateY(0);
                opacity: 1;
            }
            to {
                transform: translateY(-20px);
                opacity: 0;
            }
        }

        .flash-message.fade-out {
            animation: slideOutUp 0.4s ease forwards;
        }
        
        .flash-success {
            background-color: #f5f5f5;
            border: 1px solid #e6e6e6;
            color: #222;
        }
        
        .flash-error {
            background-color: #f8d7da;
            border: 1px solid #f5c6cb;
            color: #721c24;
        }
        
        @media (max-width: 768px) {
            .container {
                padding: 0 16px;
            }
            nav {
                width: calc(100% - 32px);
                left: 16px;
                right: 16px;
                top: 16px;
            }
            
            .nav-links {
                gap: 1rem;
            }
            
            .translate-container {
                padding: 0;
                margin: 0 8px 2rem;
                flex-direction: row; /* 태블릿은 데스크톱과 동일한 2열 */
                gap: 1.5rem;
            }

            .pdf-preview-section {
                order: 0;
                width: calc(50% - 1rem);
                flex: 0 0 calc(50% - 1rem);
            }

            .pdf-upload-section {
                order: 0;
                width: calc(50% - 1rem);
                flex: 0 0 calc(50% - 1rem);
            }
            
            .translate-header h1 {
                font-size: 2rem;
            }
            
            .upload-area {
                padding: 2.5rem 1.5rem 0; /* 하단 패딩 제거 */
            }
            
            .options-section {
                grid-template-columns: 1fr;
            }
            
            /* 태블릿용 다운로드 배너 최적화 */
            .download-banner {
                padding: 16px;
            }
            
            .banner-content {
                max-width: 420px;
            }
        }
        
        @media (max-width: 480px) {
            .container {
                padding: 0 12px;
            }
            nav {
                width: calc(100% - 24px);
                left: 12px;
                right: 12px;
                top: 12px;
            }
            /* 모바일에서 고정 네비게이션 높이로 인해 상단 제목이 가려지는 현상 보정 */
            .main-content {
                padding: 160px 0 40px 0; /* 더 여유를 줌 */
            }
            
            .translate-container {
                padding: 1.5rem 1rem;
                margin: 0 4px 1.5rem;
                flex-direction: column; /* 모바일은 세로 스크롤 순서 */
            }

            /* 모바일(폰)에서도 각 섹션이 가로폭을 가득 차도록 */
            .pdf-upload-section,
            .pdf-preview-section {
                width: 100%;
                flex: 0 0 100%;
            }

            .pdf-upload-section { order: 1; }
            .pdf-preview-section { order: 2; }
            
            .translate-header h1 {
                font-size: 1.75rem;
            }
            
            .translate-header p {
                font-size: 1rem;
            }
            
            .upload-area {
                padding: 2.5rem 1rem 0; /* 하단 패딩 제거 */
            }
            
            .upload-area h3 {
                font-size: 1.125rem; /* 모바일에서는 조금 더 작게 */
            }
            
            .upload-area p {
                font-size: 0.875rem;
            }
            
            .file-info {
                padding: 1rem;
                flex-direction: column;
                text-align: center;
                gap: 0.75rem;
            }
            
            .file-details {
                text-align: center;
            }
            
            .option-group {
                padding: 1rem;
            }
            
            .progress-section {
                padding: 1.25rem;
            }

            .progress-card-header {
                flex-wrap: wrap;
                gap: 0.5rem;
            }

            .progress-title {
                font-size: 1rem;
            }

            .progress-percentage {
                font-size: 1.25rem;
            }
            
            .nav-links {
                flex-direction: column;
                gap: 0.5rem;
            }
            
            .user-info {
                margin-right: 0;
                margin-bottom: 0.5rem;
                max-width: 70vw; /* 모바일에서 더 여유 */
                white-space: normal;
                word-break: break-word;
            }
            
            /* 모바일용 다운로드 배너 최적화 */
            .download-banner {
                padding: 12px;
            }
            
            .banner-content {
                max-width: none;
                width: 100%;
                margin: 0;
            }
            
            .banner-header {
                padding: 20px 16px 16px;
            }
            
            .banner-header h3 {
                font-size: 20px;
                margin-bottom: 6px;
            }
            
            .banner-header p {
                font-size: 14px;
                line-height: 1.4;
            }
            
            .banner-icon {
                width: 40px;
                height: 40px;
                font-size: 20px;
                margin-bottom: 12px;
            }
            
            .banner-actions {
                padding: 20px 16px 24px;
            }
            
            .download-btn {
                width: 100%;
                padding: 14px 24px;
                font-size: 15px;
                min-width: none;
            }
            
            .close-banner-btn {
                top: 12px;
                right: 12px;
                font-size: 20px;
                padding: 6px;
            }
        }
        
        /* 매우 작은 화면 (320px 이하) 최적화 */
        @media (max-width: 320px) {
            .download-banner {
                padding: 8px;
            }
            
            .banner-header {
                padding: 16px 12px 12px;
            }
            
            .banner-header h3 {
                font-size: 18px;
                margin-bottom: 4px;
            }
            
            .banner-header p {
                font-size: 13px;
            }
            
            .banner-icon {
                width: 36px;
                height: 36px;
                font-size: 18px;
                margin-bottom: 10px;
            }
            
            .banner-actions {
                padding: 16px 12px 20px;
            }
            
            .download-btn {
                padding: 12px 20px;
                font-size: 14px;
            }
        }
        
        .spinner {
            display: inline-block;
            width: 20px;
            height: 20px;
            border: 3px solid rgba(255, 255, 255, 0.3);
            border-radius: 50%;
            border-top-color: white;
            animation: spin 1s ease-in-out infinite;
        }
        
        @keyframes spin {
            to { transform: rotate(360deg); }
        }
        
        /* 번역 완료 다운로드 배너 - 중앙 모달 스타일 */
        .download-banner {
            position: fixed;
            top: 0;
            left: 0;
            width: 100vw;
            height: 100vh;
            z-index: 10000;
            align-items: center;
            justify-content: center;
            padding: 20px;
            animation: fadeIn 0.3s ease-out;
            box-sizing: border-box;
            display: none;
        }
        
        .download-banner.show {
            display: flex;
        }
        
        /* 어두운 배경 오버레이 */
        .download-banner::before {
            content: '';
            position: absolute;
            top: 0;
            left: 0;
            width: 100%;
            height: 100%;
            background: rgba(0, 0, 0, 0.7);
            backdrop-filter: blur(4px);
            z-index: -1;
        }
        
        .banner-content {
            position: relative;
            background: #ffffff;
            border-radius: 16px;
            box-shadow: 0 20px 40px rgba(0, 0, 0, 0.15), 0 8px 16px rgba(0, 0, 0, 0.1);
            max-width: 480px;
            width: 100%;
            overflow: hidden;
            animation: slideUp 0.4s ease-out;
            z-index: 1;
        }
        
        .banner-header {
            background: linear-gradient(135deg, #10b981, #0fb26f);
            color: white;
            padding: 24px 32px 20px;
            text-align: center;
            position: relative;
        }
        
        .banner-icon {
            display: inline-flex;
            align-items: center;
            justify-content: center;
            width: 48px;
            height: 48px;
            background: rgba(255, 255, 255, 0.15);
            border-radius: 50%;
            font-size: 24px;
            margin-bottom: 16px;
            color: white;
        }
        
        .banner-header h3 {
            margin: 0 0 8px 0;
            font-size: 24px;
            font-weight: 700;
            color: white;
        }
        
        .banner-header p {
            margin: 0;
            font-size: 16px;
            color: rgba(255, 255, 255, 0.9);
            line-height: 1.5;
        }
        
        .close-banner-btn {
            position: absolute;
            top: 16px;
            right: 16px;
            background: none;
            border: none;
            color: rgba(255, 255, 255, 0.8);
            font-size: 24px;
            cursor: pointer;
            padding: 8px;
            border-radius: 8px;
            transition: all 0.2s ease;
            line-height: 1;
        }
        
        .close-banner-btn:hover {
            color: white;
            background: rgba(255, 255, 255, 0.15);
        }
        
        .banner-actions {
            padding: 32px;
            text-align: center;
            display: flex;
            justify-content: center;
            gap: 12px;
            flex-wrap: wrap;
        }

        .download-status {
            width: 100%;
            margin: 8px 0 0;
            min-height: 20px;
            font-size: 14px;
            line-height: 1.4;
            color: #64748b;
        }

        .download-status.error {
            color: #dc2626;
        }

        .download-status.info {
            color: #2563eb;
        }
        
        .download-btn {
            border: none;
            padding: 16px 32px;
            border-radius: 12px;
            font-size: 16px;
            font-weight: 600;
            cursor: pointer;
            transition: all 0.3s ease;
            min-width: 140px;
        }

        .download-btn.primary {
            background: linear-gradient(135deg, #10b981, #0fb26f);
            color: white;
            box-shadow: 0 4px 12px rgba(15, 178, 111, 0.3);
        }

        .download-btn.primary:hover:not(:disabled) {
            background: linear-gradient(135deg, #0d9668, #0ca05c);
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(15, 178, 111, 0.4);
        }

        .download-btn.outline {
            background: white;
            color: #111;
            border: 1.5px solid #111;
            box-shadow: none;
        }

        .download-btn.outline:hover:not(:disabled) {
            background: #f8fafc;
            transform: translateY(-2px);
        }

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

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

        @keyframes fadeIn {
            from {
                opacity: 0;
            }
            to {
                opacity: 1;
            }
        }
        
        @keyframes slideUp {
            from {
                opacity: 0;
                transform: translateY(40px) scale(0.95);
            }
            to {
                opacity: 1;
                transform: translateY(0) scale(1);
            }
        }

        /* 둥둥 떠있는 배지 스타일 */
        .plan-badges {
            display: flex;
            justify-content: center;
            align-items: center;
            gap: 0.75rem;
            margin: 1rem 0rem; /* 배지 아래 여백 절반으로 축소 */
        }

        .plan-badge {
            background: rgba(255, 255, 255, 0.7);
            backdrop-filter: blur(10px);
            border: 1px solid rgba(255, 98, 8, 0.6);
            border-radius: 20px;
            padding: 0.5rem 1rem;
            font-size: 0.875rem;
            font-weight: 600;
            color: var(--text-primary);
            box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
            transition: all 0.3s ease;
        }

        .floating-badge:nth-child(1) {
            animation: float1 3s ease-in-out infinite;
        }

        .floating-badge:nth-child(2) {
            animation: float2 3.7s ease-in-out infinite;
        }

        .plan-badge:hover {
            transform: translateY(-2px);
            box-shadow: 0 6px 20px rgba(0, 0, 0, 0.15);
            animation-play-state: paused;
        }

        @keyframes float1 {
            0%, 100% {
                transform: translateY(0px);
            }
            50% {
                transform: translateY(-4px);
            }
        }

        @keyframes float2 {
            0%, 100% {
                transform: translateY(0px);
            }
            25% {
                transform: translateY(-2px);
            }
            50% {
                transform: translateY(-4px);
            }
            75% {
                transform: translateY(-2px);
            }
        }


        /* 섹션 컨테이너 스타일 */
        .section-container {
            background-color: var(--white);
            border-radius: 16px;
            box-shadow: var(--shadow-md);
            padding: 1.5rem 2rem 2rem; /* 상단 패딩을 미리보기 섹션과 동일하게 */
            margin-bottom: 1.5rem;
            border: 1px solid var(--border);
        }

        /* 번역 설정 섹션의 선택 박스 아래 여백 축소 */
        .section-container.settings-section {
            padding: 1.5rem 2rem 1.5rem; /* 하단 패딩만 줄임 */
        }

        .section-header {
            position: relative;
            display: flex;
            align-items: center;
            gap: 0.75rem;
            margin-bottom: 1rem; /* pdf 미리보기 헤더와 동일 간격 */
            padding-bottom: 0.75rem; /* pdf 미리보기 헤더와 동일 간격 */
            border-bottom: 1px solid var(--border-light);
        }

        .section-icon {
            flex-shrink: 0;
        }

        .section-title {
            font-size: 1.125rem; /* PDF 미리보기 제목과 동일한 크기 */
            font-weight: 600;
            color: var(--text-primary);
            margin: 0;
        }

        @media (max-width: 480px) {
            .plan-badges {
                gap: 0.5rem;
            }
            
            .plan-badge {
                padding: 0.4rem 0.8rem;
                font-size: 0.8rem;
            }

            .section-container {
                padding: 1.5rem;
            }

            /* 모바일에서도 선택 박스 아래 여백 축소 유지 */
            .section-container.settings-section {
                padding: 1.5rem 1.5rem 1.5rem;
            }

            .section-header {
                margin-bottom: 1rem;
                padding-bottom: 0.75rem;
            }

            .section-title {
                font-size: 1.125rem;
            }
        }
