/* ==========================================
   Common Styles - 공통 스타일
   PC와 모바일 모두에서 사용되는 기본 스타일
   ========================================== */

:root {
    /* Light theme colors */
    --background: #ffffff;
    --foreground: #0f172a;
    --card: #ffffff;
    --card-foreground: #0f172a;
    --primary: #3b82f6;
    --primary-foreground: #ffffff;
    --secondary: #f1f5f9;
    --secondary-foreground: #0f172a;
    --muted: #f1f5f9;
    --muted-foreground: #64748b;
    --accent: #f1f5f9;
    --accent-foreground: #0f172a;
    --border: #e2e8f0;
    --input: #e2e8f0;
    --ring: #3b82f6;
    --radius: 0.5rem;
    --success-color: #22c55e;
    --destructive: #ef4444;
    --destructive-foreground: #ffffff;
    
    /* Sidebar specific */
    --sidebar-background: var(--card);
    --sidebar-foreground: var(--card-foreground);
    --sidebar-border: var(--border);
}

.dark {
    /* Dark theme colors */
    --background: #0f172a;
    --foreground: #f8fafc;
    --card: #1e293b;
    --card-foreground: #f8fafc;
    --primary: #3b82f6;
    --primary-foreground: #ffffff;
    --secondary: #334155;
    --secondary-foreground: #f8fafc;
    --muted: #334155;
    --muted-foreground: #94a3b8;
    --accent: #334155;
    --accent-foreground: #f8fafc;
    --border: #334155;
    --input: #334155;
    --ring: #3b82f6;
    --success-color: #22c55e;
    --destructive: #ef4444;
    --destructive-foreground: #ffffff;
}

* {
    box-sizing: border-box;
}

body {
    font-family: 'Inter', system-ui, sans-serif;
    background-color: var(--background);
    color: var(--foreground);
    margin: 0;
    padding: 0;
    min-height: 100vh;
    -webkit-font-smoothing: antialiased;
}

/* Canvas 공통 스타일 */
#imageCanvas {
    border: 1px solid var(--border);
    cursor: crosshair;
    border-radius: var(--radius);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.canvas-container {
    display: flex;
    justify-content: center;
    align-items: center;
    background-color: var(--muted);
    border-radius: var(--radius);
    position: relative;
}

.canvas-container.empty {
    background: repeating-conic-gradient(#f0f0f0 0% 25%, #e0e0e0 0% 50%) 50% / 60px 60px;
}

.panel-title {
    display: flex;
    align-items: center;
    justify-content: flex-start; /* 제목과 아이콘, 셀렉트를 좌측 정렬 */
    gap: 0.5rem;
}

.panel-title-left {
    display: flex;
    align-items: center;
    gap: 0.4rem; /* 아이콘-텍스트 간격 조금 축소 */
}

.panel-inline-control {
    flex-shrink: 0;
    min-width: 120px;
}

.panel-inline-control select {
    width: auto;
    min-width: 120px;
    font-size: 0.8rem;
}

.empty-state {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    padding: 2rem;
    color: var(--muted-foreground);
    text-align: center;
}

.empty-state .material-icons {
    font-size: 4rem;
    opacity: 0.5;
}

/* 버튼 공통 스타일 */
button {
    background-color: var(--primary);
    color: var(--primary-foreground);
    border: none;
    padding: 0.5rem 1rem;
    border-radius: var(--radius);
    cursor: pointer;
    font-size: 0.875rem;
    font-weight: 500;
    transition: all 0.2s ease;
}

button:hover {
    opacity: 0.9;
    transform: translateY(-1px);
}

button:active {
    transform: translateY(0);
}

/* 입력 요소 공통 스타일 */
select, input {
    padding: 0.5rem;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    background-color: var(--background);
    color: var(--foreground);
    font-size: 0.875rem;
}

select:focus, input:focus {
    outline: none;
    border-color: var(--ring);
    box-shadow: 0 0 0 2px rgba(59, 130, 246, 0.1);
}

/* Material Icons */
.material-icons {
    font-family: 'Material Icons';
    font-weight: normal;
    font-style: normal;
    font-size: 24px;
    line-height: 1;
    letter-spacing: normal;
    text-transform: none;
    display: inline-block;
    white-space: nowrap;
    word-wrap: normal;
    direction: ltr;
    -webkit-font-feature-settings: 'liga';
    -webkit-font-smoothing: antialiased;
}