/* 기본 스타일 및 폰트 설정 */
:root {
    --primary-color: #007bff;
    --light-gray: #f8f9fa;
    --dark-gray: #343a40;
    --border-color: #dee2e6;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    margin: 0;
    background-color: var(--light-gray);
    color: var(--dark-gray);
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* 헤더 및 내비게이션 */
.main-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color);
}

.logo {
    margin: 0;
    font-size: 1.8em;
    color: var(--primary-color);
}

.category-nav ul {
    margin: 0;
    padding: 0;
    list-style: none;
}

.category-nav li {
    display: inline-block;
    margin-left: 25px;
}

.category-nav a {
    text-decoration: none;
    color: var(--dark-gray);
    font-weight: 500;
}

/* 콘텐츠 영역 */
.content-area {
    display: flex;
    gap: 30px;
    margin-top: 30px;
    min-height: 500px;
}

.main-content {
    flex: 3;
}

.sidebar {
    flex: 1;
}

/* 연결 박스 */
.connection-box {
    background: #fff;
    padding: 40px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
}

.connection-box h2 { margin-top: 0; }

.input-group { margin-bottom: 20px; }
.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
}
.input-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 5px;
    font-size: 1em;
    box-sizing: border-box;
}

.connect-button {
    width: 100%;
    padding: 15px;
    background-color: var(--primary-color);
    color: #fff;
    border: none;
    border-radius: 5px;
    font-size: 1.1em;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s;
}
.connect-button:hover { background-color: #0056b3; }
.connect-button:disabled { background-color: #ccc; cursor: not-allowed; }

/* 상태 표시 */
.status-indicator {
    padding: 10px;
    background: #e9ecef;
    border-radius: 4px;
    margin-bottom: 20px;
    text-align: center;
    font-weight: bold;
    color: #495057;
}

/* 프로그레스 바 */
.progress-bar-container {
    width: 100%;
    background-color: #e9ecef;
    border-radius: 5px;
    overflow: hidden;
    height: 20px;
    margin: 10px 0;
}
.progress-bar {
    width: 0%;
    height: 100%;
    background-color: #28a745;
    transition: width 0.3s ease;
}

/* 사이드바 위젯 */
.widget {
    background: #fff;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 8px rgba(0,0,0,0.05);
    margin-bottom: 20px;
}

.ad-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 250px;
    background-color: #f1f3f5;
    border: 1px dashed #ced4da;
    color: #adb5bd;
}

.other-content ul { list-style: none; padding: 0; }
.other-content li {
    padding: 8px 0;
    border-bottom: 1px solid var(--border-color);
}
.other-content li:last-child { border-bottom: none; }
.other-content a { color: #495057; text-decoration: none; }
.other-content a:hover { color: var(--primary-color); }

/* 푸터 */
.main-footer {
    text-align: center;
    padding: 40px 0;
    margin-top: 40px;
    border-top: 1px solid var(--border-color);
    color: #6c757d;
}

@media (max-width: 768px) {
    .content-area { flex-direction: column; }
    .main-header { flex-direction: column; gap: 15px; }
    .category-nav li { margin: 0 10px; }
}
