/* Pretendard 폰트 추가 */
@import url('https://cdn.jsdelivr.net/gh/orioncactus/pretendard@v1.3.8/dist/web/static/pretendard.css');

/* 기본 스타일 */
html, body {
    font-family: 'Pretendard', -apple-system, BlinkMacSystemFont, system-ui, Roboto, 'Helvetica Neue', 'Segoe UI', sans-serif;
}

/* 애니메이션 효과 */
.hover-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    cursor: pointer;
}

.hover-card:hover {
    transform: translateY(-4px);
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
}

/* 그라데이션 배경 */
.gradient-primary {
    background: linear-gradient(135deg, #FFA500 0%, #FFD700 100%);
}

.gradient-success {
    background: linear-gradient(135deg, #4CAF50 0%, #66BB6A 100%);
}

/* 텍스트 스타일 */
.text-muted {
    opacity: 0.7;
}

/* 카드 스타일 */
.mud-card {
    border-radius: 12px !important;
    overflow: hidden;
}

.mud-card-header {
    background-color: rgba(0,0,0,0.02);
    border-bottom: 1px solid rgba(0,0,0,0.08);
}

/* 버튼 스타일 */
.mud-button-root {
    border-radius: 8px !important;
    text-transform: none !important;
    font-weight: 500;
}

/* 네비게이션 스타일 */
.mud-nav-link {
    border-radius: 8px !important;
    margin: 4px 8px !important;
    transition: all 0.2s ease;
}

.mud-nav-link:hover {
    background-color: rgba(255, 165, 0, 0.08) !important;
}

.mud-nav-link-active {
    background-color: rgba(255, 165, 0, 0.12) !important;
}

/* 테이블 스타일 */
.mud-table {
    border-radius: 8px !important;
    overflow: hidden;
}

.mud-table-head {
    background-color: rgba(0,0,0,0.04);
}

/* 차트 컨테이너 */
.chart-container {
    position: relative;
    height: 300px;
    width: 100%;
}

/* 로딩 애니메이션 */
@keyframes pulse {
    0% {
        opacity: 1;
    }
    50% {
        opacity: 0.5;
    }
    100% {
        opacity: 1;
    }
}

.loading-pulse {
    animation: pulse 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}

/* 스크롤바 스타일 */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: #f1f1f1;
}

::-webkit-scrollbar-thumb {
    background: #FFA500;
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: #FF8C00;
}

/* 반응형 스타일 */
@media (max-width: 600px) {
    .mud-drawer-open-responsive-xs-left .mud-main-content {
        margin-left: 0 !important;
    }
}

/* 다크 모드 지원 */
@media (prefers-color-scheme: dark) {
    .mud-card-header {
        background-color: rgba(255,255,255,0.02);
        border-bottom: 1px solid rgba(255,255,255,0.08);
    }
    
    .mud-table-head {
        background-color: rgba(255,255,255,0.04);
    }
}

/* 클릭 가능한 행 스타일 */
.cursor-pointer {
    cursor: pointer !important;
}

.cursor-pointer:hover {
    background-color: rgba(0, 0, 0, 0.04) !important;
    transition: background-color 0.2s ease;
}

/* Draft Data Grid 스타일 - 최대 우선순위 */
.mud-table .mud-table-row.draft-row > td,
.mud-table .mud-table-row.draft-row:hover > td,
.mud-datagrid .mud-table-row.draft-row > td,
.mud-datagrid .mud-table-row.draft-row:hover > td {
    background-color: rgba(255, 235, 59, 0.3) !important;
}

.mud-table .mud-table-row.draft-row,
.mud-table .mud-table-row.draft-row:hover,
.mud-datagrid .mud-table-row.draft-row,
.mud-datagrid .mud-table-row.draft-row:hover {
    border-left: 4px solid #FFC107 !important;
}

.mud-table .mud-table-row.modified-row > td,
.mud-table .mud-table-row.modified-row:hover > td,
.mud-datagrid .mud-table-row.modified-row > td,
.mud-datagrid .mud-table-row.modified-row:hover > td {
    background-color: rgba(33, 150, 243, 0.25) !important;
}

.mud-table .mud-table-row.modified-row,
.mud-table .mud-table-row.modified-row:hover,
.mud-datagrid .mud-table-row.modified-row,
.mud-datagrid .mud-table-row.modified-row:hover {
    border-left: 4px solid #2196F3 !important;
}

.mud-table .mud-table-row.error-row > td,
.mud-table .mud-table-row.error-row:hover > td,
.mud-datagrid .mud-table-row.error-row > td,
.mud-datagrid .mud-table-row.error-row:hover > td {
    background-color: rgba(244, 67, 54, 0.25) !important;
}

.mud-table .mud-table-row.error-row,
.mud-table .mud-table-row.error-row:hover,
.mud-datagrid .mud-table-row.error-row,
.mud-datagrid .mud-table-row.error-row:hover {
    border-left: 4px solid #F44336 !important;
}

.saved-row {
    /* Default styling, no special background */
}

.draft-status-bar {
    padding: 12px 16px;
    background: #f5f5f5;
    border-radius: 4px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.draft-toolbar {
    display: flex;
    align-items: center;
    gap: 12px;
}