/* ========================================
   Design System - Variables
   ======================================== */
:root {
    /* Primary Colors */
    --primary-blue: #1E40AF;
    --primary-blue-light: #3B82F6;
    --primary-blue-dark: #1E3A8A;
    --primary-orange: #F97316;
    
    /* Status Colors */
    --status-pending: #FFA500;
    --status-pending-bg: #FFF7E6;
    --status-confirmed: #4CAF50;
    --status-confirmed-bg: #E8F5E9;
    --status-shipping: #2196F3;
    --status-shipping-bg: #E3F2FD;
    --status-completed: #9E9E9E;
    --status-completed-bg: #F5F5F5;
    
    /* UI Colors */
    --background: #F5F7FA;
    --card-bg: #FFFFFF;
    --text-primary: #212121;
    --text-secondary: #757575;
    --text-light: #9E9E9E;
    --border: #E0E0E0;
    --border-light: #F0F0F0;
    
    /* Accent Colors */
    --success: #4CAF50;
    --warning: #FF9800;
    --error: #F44336;
    --info: #2196F3;
    
    /* Spacing */
    --space-xs: 4px;
    --space-sm: 8px;
    --space-md: 16px;
    --space-lg: 24px;
    --space-xl: 32px;
    
    /* Border Radius */
    --radius-sm: 4px;
    --radius-md: 8px;
    --radius-lg: 12px;
    --radius-xl: 16px;
    
    /* Shadows */
    --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
    --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
    --shadow-lg: 0 10px 15px rgba(0, 0, 0, 0.1);
    
    /* Touch Target */
    --touch-target-min: 44px;

	/* Grayscale (common.css) */
    --white: #ffffff;
    --gray-50: #f8f9fa;
    --gray-100: #e9ecef;
    --gray-200: #dee2e6;
    --gray-300: #ced4da;
    --gray-400: #adb5bd;
    --gray-500: #6c757d;
    --gray-600: #495057;
    --gray-700: #343a40;
    --gray-800: #212529;
    --gray-900: #1a1d20;
}


/* ========================================
   font Styles
   ======================================== */

@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Thin.woff2') format('woff2');
    font-weight: 100;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-ExtraLight.woff2') format('woff2');
    font-weight: 200;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Light.woff2') format('woff2');
    font-weight: 300;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Regular.woff2') format('woff2');
    font-weight: 400;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Medium.woff2') format('woff2');
    font-weight: 500;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-SemiBold.woff2') format('woff2');
    font-weight: 600;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Bold.woff2') format('woff2');
    font-weight: 700;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-ExtraBold.woff2') format('woff2');
    font-weight: 800;
    font-display: swap;
}
@font-face {
    font-family: 'Pretendard';
    src: url('/assets/fonts/Pretendard-Black.woff2') format('woff2');
    font-weight: 900;
    font-display: swap;
}

/* ========================================
   Reset & Base Styles
   ======================================== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    font-size: 16px;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: 'Pretendard', sans-serif;
    color: var(--text-primary);
    background: var(--background);
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    /*padding-bottom: 80px;*/
}

/* ========================================
   Header
   ======================================== */
.header {
    background: linear-gradient(135deg, var(--primary-blue-dark) 0%, var(--primary-blue) 100%);
    color: white;
    padding: var(--space-md);
    box-shadow: var(--shadow-md);
    position: sticky;
    top: 0;
    z-index: 100;
}

.header-content {
    display: flex;
    align-items: center;
    justify-content: space-between;
    max-width: 600px;
    margin: 0 auto;
}

.logo {
    font-size: 24px;
    font-weight: 700;
    letter-spacing: -0.5px;
}

.company-name {
    font-size: 14px;
    flex: 1;
    /*text-align: center;*/
    /*opacity: 0.9;*/
	font-weight: 700;
}

.btn-logout {
    background: rgba(255, 255, 255, 0.2);
    color: white;
    border: 1px solid rgba(255, 255, 255, 0.3);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-lg);
    font-size: 14px;
    cursor: pointer;
    min-height: var(--touch-target-min);
    transition: all 0.3s ease;
}

.btn-logout:hover {
    background: rgba(255, 255, 255, 0.3);
}

/* ========================================
   Navigation Tabs
   ======================================== */
.nav-tabs {
    display: flex;
    background: white;
    border-bottom: 1px solid var(--border-light);
    position: sticky;
    top: 92px;
    z-index: 90;
    box-shadow: var(--shadow-sm);
}

.nav-tab {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-md);
    text-decoration: none;
    color: var(--text-secondary);
    border-bottom: 3px solid transparent;
    transition: all 0.3s ease;
    min-height: var(--touch-target-min);
}

.nav-tab i {
    font-size: 20px;
}

.nav-tab span {
    font-size: 12px;
    font-weight: 500;
}

.nav-tab.active {
    color: var(--primary-blue);
    border-bottom-color: var(--primary-blue);
    background: var(--status-confirmed-bg);
}

.nav-tab:hover {
    background: var(--background);
}

/* ========================================
   Main Content
   ======================================== */
.main-content {
    max-width: 600px;
    margin: 0 auto;
    padding: var(--space-md);
}

/* ========================================
   Filter Section
   ======================================== */
.filter-section {
    background: white;
    padding: var(--space-md);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    margin-bottom: var(--space-md);
}

.date-filter {
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    margin-bottom: var(--space-md);
	flex-wrap: wrap;
}

.input-date {
    flex: 1;
	min-width: 0;
    box-sizing: border-box;
    padding: var(--space-sm);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 16px;
    min-height: 40px;
    transition: all 0.3s ease;
}

.input-date:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.date-separator {
    color: var(--text-secondary);
    font-weight: 500;
	flex-shrink: 0;
}

.btn-primary {
    background: var(--primary-blue);
    color: white;
    border: none;
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    min-height: 40px;
    width: 100%;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
}

.btn-primary:hover {
    background: var(--primary-blue-dark);
    transform: translateY(-1px);
    box-shadow: var(--shadow-md);
}

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

/* ========================================
   Status Tabs
   ======================================== */
.status-tabs {
    display: flex;
    gap: var(--space-sm);
    margin-bottom: var(--space-md);
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;

	/* ½ºÅ©·Ñ¹Ù ¼û±â±â */
    -ms-overflow-style: none;   /* IE, Edge */
    scrollbar-width: none;      /* Firefox */
}

.status-tabs::-webkit-scrollbar {
    display: none;              /* Chrome, Safari, iOS */
}


.status-tab {
    flex: 1;
    min-width: fit-content;
    padding: var(--space-sm);
    background: white;
    border: 2px solid var(--border);
    border-radius: var(--radius-lg);
    font-size: 14px;
    font-weight: 600;
    color: var(--text-secondary);
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-xs);
    /*min-height: var(--touch-target-min);*/
	*min-height: 30px;
}

.status-tab.active {
    background: var(--primary-blue);
    color: white;
    border-color: var(--primary-blue);
    box-shadow: var(--shadow-md);
}

.badge {
    background: var(--border);
    color: var(--text-secondary);
    padding: 2px 8px;
    border-radius: 12px;
    font-size: 12px;
    font-weight: 700;
}

.status-tab.active .badge {
    background: rgba(255, 255, 255, 0.3);
    color: white;
}

.badge-pending {
    background: var(--status-pending-bg);
    color: var(--status-pending);
}

.badge-confirmed {
    background: var(--status-confirmed-bg);
    color: var(--status-confirmed);
}

.badge-completed {
    background: var(--status-completed-bg);
    color: var(--status-completed);
}


.badge-S {
    background: linear-gradient(135deg, #FFE5E5 0%, #FFF0F0 100%);
    color: #FF6B9D;
}

.badge-G {
    background: linear-gradient(135deg, #112F82 0%, #1a3d9e 100%);
    color: white;
}

.badge-P {
    background-color: #66BB6A;  /* ³ì»ö ¹è°æ */
    color: #FFFFFF;  /* ÅØ½ºÆ®´Â Èò»öÀ¸·Î ¼³Á¤ */
}

.badge-E {
    background-color: #dee2e6;
    color: #343a40;
}

/* ========================================
   Sort Section
   ======================================== */
.sort-section {
    margin-bottom: var(--space-md);
    display: flex;
    justify-content: flex-end;
}

.sort-select {
    padding: var(--space-sm) var(--space-md);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    background: white;
    font-size: 14px;
    color: var(--text-primary);
    cursor: pointer;
    min-height: 36px;
}

/* ========================================
   Order List & Cards
   ======================================== */
.order-list {
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.order-card {
    background: white;
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-sm);
    overflow: hidden;
    transition: all 0.3s ease;
}

.order-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.order-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-md);
    background: var(--background);
    border-bottom: 1px solid var(--border-light);
}

.status-badge {
    display: inline-flex;
    align-items: center;
    gap: var(--space-xs);
    padding: var(--space-xs) var(--space-md);
    border-radius: var(--radius-lg);
    font-size: 14px;
    font-weight: 600;
}

.status-badge i {
    font-size: 16px;
}

.status-pending {
    background: var(--status-pending-bg);
    color: var(--status-pending);
}

.status-confirmed {
    background: var(--status-confirmed-bg);
    color: var(--status-confirmed);
}

.status-shipping {
    background: var(--status-shipping-bg);
    color: var(--status-shipping);
}

.status-completed {
    background: var(--status-completed-bg);
    color: var(--status-completed);
}

.order-number {
    font-size: 12px;
    color: var(--text-secondary);
    font-weight: 500;
}

.order-info {
    padding: var(--space-md);
    display: flex;
    flex-direction: column;
    gap: var(--space-md);
}

.info-row {
    display: flex;
    align-items: flex-start;
    gap: var(--space-sm);
    font-size: 14px;
}

.info-row i {
    color: var(--primary-blue);
    width: 20px;
    margin-top: 2px;
}

.info-row .label {
    color: var(--text-secondary);
    min-width: 80px;
}

.info-row .value {
    color: var(--text-primary);
    font-weight: 500;
    flex: 1;
}

.order-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: var(--space-md);
    background: var(--background);
    border-top: 1px solid var(--border-light);
}

.order-amount {
    display: flex;
    flex-direction: column;
    gap: var(--space-xs);
}

.amount-label {
    font-size: 12px;
    color: var(--text-secondary);
}

.amount-value {
    font-size: 20px;
    font-weight: 700;
    color: var(--primary-blue);
}

.btn-detail {
    background: var(--primary-blue);
    color: white;
    text-decoration: none;
    padding: var(--space-md) var(--space-lg);
    border-radius: var(--radius-md);
    font-size: 14px;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: var(--space-sm);
    transition: all 0.3s ease;
    min-height: var(--touch-target-min);
}

.btn-detail:hover {
    background: var(--primary-blue-dark);
}

/* ========================================
   Floating Action Button
   ======================================== */
.fab {
    position: fixed;
    bottom: 80px;
    right: 20px;
    width: 56px;
    height: 56px;
    background: var(--primary-orange);
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: var(--shadow-lg);
    text-decoration: none;
    font-size: 24px;
    transition: all 0.3s ease;
    z-index: 50;
}

.fab:hover {
    transform: scale(1.1) rotate(90deg);
    box-shadow: 0 15px 25px rgba(0, 0, 0, 0.2);
}

/* ========================================
   Form Elements
   ======================================== */
.form-group {
    margin-bottom: var(--space-lg);
}

.form-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: var(--text-primary);
    margin-bottom: var(--space-sm);
}

.form-label.required::after {
    content: " *";
    color: var(--error);
}

.form-input,
.form-textarea,
.form-select {
    width: 100%;
    padding: var(--space-sm);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
    min-height: 48px;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
    outline: none;
    border-color: var(--primary-blue);
    box-shadow: 0 0 0 3px rgba(30, 64, 175, 0.1);
}

.form-textarea {
    min-height: 120px;
    resize: vertical;
}

.form-hint {
    display: block;
    font-size: 12px;
    color: var(--text-secondary);
    margin-top: var(--space-xs);
}

/* Ãß°¡ */
.form-none {
    width: 100%;
    padding: var(--space-md);
    border: 2px solid var(--border);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-family: inherit;
    transition: all 0.3s ease;
	background-color: #e8e8e8;
    min-height: 48px;
}

/* ========================================
   Button Group
   ======================================== */
.btn-group {
    display: flex;
    gap: var(--space-sm);
}

.btn-secondary {
    background: white;
    color: var(--primary-blue);
    border: 2px solid var(--primary-blue);
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    min-height: 48px;
    flex: 1;
    transition: all 0.3s ease;
}

.btn-secondary:hover {
    background: var(--background);
}

.btn-success {
    background: var(--success);
    color: white;
    border: none;
    padding: var(--space-sm) var(--space-md);
    border-radius: var(--radius-md);
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    min-height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: var(--space-sm);
}

.btn-success:hover {
    background: #388E3C;
}

.btn-lg {
    padding: 18px 36px;
    font-size: 16px;
}

.btn-sm {
    padding: 10px 20px;
    font-size: 13px;
}

.btn-xs {
    padding: 8px 18px;
    font-size: 13px;
}

.btn-block {
    width: 100%;
    display: flex;
}



/* ========================================
   Utility Classes
   ======================================== */
.text-center {
    text-align: center;
}

.mt-sm { margin-top: var(--space-sm); }
.mt-md { margin-top: var(--space-md); }
.mt-lg { margin-top: var(--space-lg); }

.mb-sm { margin-bottom: var(--space-sm); }
.mb-md { margin-bottom: var(--space-md); }
.mb-lg { margin-bottom: var(--space-lg); }

.hidden {
    display: none !important;
}



/* Form Actions */
.form-actions {
    margin-top: var(--space-lg);
}

.sticky-bottom {
    position: sticky;
    bottom: 0;
    background: white;
    padding: var(--space-md);
    box-shadow: 0 -4px 6px rgba(0, 0, 0, 0.05);
    margin: 0 calc(-1 * var(--space-sm));
    margin-top: var(--space-lg);
}




/* ========================================
   Loading Spinner Classes (common.css)
   ======================================== */

/* Loading Spinner */
.loading {
    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); }
}

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: 9999;
    backdrop-filter: blur(4px);
}

.loading-spinner {
    width: 60px;
    height: 60px;
    border: 5px solid rgba(255, 255, 255, 0.3);
    border-radius: 50%;
    border-top-color: white;
    animation: spin 1s ease-in-out infinite;
}


/* ========================================
   Modal Classes (common.css)
   ======================================== */

/* Modal */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 9999;
    /*padding: 20px;*/
    /*overflow-y: auto;*/
    backdrop-filter: blur(4px);
	align-items: flex-end;
}

.modal.show {
    display: flex;
	/*
    justify-content: center;
    align-items: flex-start;
    padding-top: 60px;
	*/
}

.modal-content {
    background: white;
    width: 100%;
    max-width: 600px;
    margin: 0 auto;
    border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    height: 90vh;
    display: flex;
    flex-direction: column;
    animation: slideUp 0.3s ease;
}

.modal-header {
    padding: var(--space-md);
    border-bottom: 1px solid var(--border);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.modal-title {
    font-size: 18px;
    font-weight: 700;
}

.modal-close {
    background: none;
    border: none;
    font-size: 28px;
    color: var(--text-light);
    cursor: pointer;
    padding: 0;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 8px;
    transition: all 0.3s ease;
}

.modal-close:hover {
    background-color: var(--gray-100);
    color: var(--text-primary);
}

.modal-body {
    padding: var(--space-md);
    overflow-y: auto;
    flex: 1;
}

.modal-footer {
    padding: 24px;
    border-top: 1px solid var(--gray-200);
    display: flex;
    justify-content: flex-end;
    gap: 12px;
}


/* ========================================
   Status Badge Classes (common.css)
   ======================================== */

/* Status Tag */
.status-tag {
    display: inline-block;
    padding: 6px 12px;
    border-radius: 16px;
    font-size: 11px;
    font-weight: 700;
	flex-shrink: 0;
}

.status-tag.S {
    background: linear-gradient(135deg, #FFE5E5 0%, #FFF0F0 100%);
    color: #FF6B9D;
}

.status-tag.G {
    background: linear-gradient(135deg, #112F82 0%, #1a3d9e 100%);
    color: white;
}

.status-tag.P {
    background-color: #66BB6A;  /* ³ì»ö ¹è°æ */
    color: #FFFFFF;  /* ÅØ½ºÆ®´Â Èò»öÀ¸·Î ¼³Á¤ */
}

.status-tag.E {
    background-color: #dee2e6;
    color: #343a40;
}

/* ========================================
   Filter Buttons Classes (common.css)
   ======================================== */

/* Filter Buttons */
.filter-buttons {
    display: flex;
    gap: 5px;
    /*margin-bottom: 5px;*/
    flex-wrap: wrap;
}

.filter-btn {
	padding: 5px 10px;
	background-color: white;
	border: 2px solid #dee2e6;
	border-radius: 12px;
	color: var(--text-secondary);
	font-size: 13px;
	font-weight: 700;
	cursor: pointer;
	transition: all 0.3s ease;
}

.filter-btn:hover {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}

.filter-btn.active {
    background: linear-gradient(135deg, var(--primary-blue) 0%, var(--primary-blue-light) 100%);
    border-color: var(--primary-blue);
    color: white;
    box-shadow: var(--shadow);
}


/* ========================================
   Card Classes (common.css)
   ======================================== */

/* Card */
.card {
    background-color: white;
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
    padding: var(--space-md);
    margin-bottom: 20px;
    transition: all 0.3s ease;
    border: 1px solid rgba(108, 99, 255, 0.08);
}

.card:hover {
    box-shadow: var(--shadow);
    transform: translateY(-4px);
}

.card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
    padding-bottom: 16px;
    border-bottom: 2px solid var(--gray-100);
}

.card-title {
    font-size: 20px;
    font-weight: 700;
    color: var(--text-primary);
}

.card-badge {
    display: inline-block;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

/* ========================================
   Empty State Classes (common.css)
   ======================================== */

/* Empty State */
.empty-state {
    text-align: center;
    padding: 80px 20px;
    color: var(--text-light);
}

.empty-state-icon {
    font-size: 72px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.empty-state-text {
    font-size: 16px;
    color: var(--text-secondary);
    font-weight: 500;
}


/* ========================================
   Responsive
   ======================================== */
@media (max-width: 600px) {
    .main-content {
        padding: var(--space-sm);
    }
    
    .header-content {
        padding: 0;
    }
    
    .company-name {
        /*font-size: 12px;*/
    }
    
    .btn-logout {
        font-size: 12px;
        padding: var(--space-xs) var(--space-sm);
    }
}