/* 販売管理システム 基本スタイル */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
:root {
    --primary: #2563eb; --primary-dark: #1d4ed8; --secondary: #64748b;
    --success: #16a34a; --danger: #dc2626; --warning: #f59e0b; --info: #0ea5e9;
    --bg: #f8fafc; --bg-white: #ffffff; --border: #e2e8f0;
    --text: #1e293b; --text-light: #64748b;
    --shadow: 0 1px 3px rgba(0,0,0,0.1); --shadow-md: 0 4px 6px rgba(0,0,0,0.1);
}
body { font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Hiragino Sans", "Hiragino Kaku Gothic ProN", Meiryo, sans-serif; font-size: 14px; line-height: 1.6; color: var(--text); background: var(--bg); }
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
.login-page { display: flex; justify-content: center; align-items: center; min-height: 100vh; background: linear-gradient(135deg, #1e3a5f 0%, #2563eb 100%); }
.login-container { background: var(--bg-white); padding: 40px; border-radius: 8px; box-shadow: var(--shadow-md); width: 100%; max-width: 400px; }
.login-container h1 { text-align: center; margin-bottom: 30px; color: var(--text); font-size: 24px; }
.login-links { text-align: center; margin-top: 20px; font-size: 13px; }
.form-group { margin-bottom: 20px; }
.form-group label { display: block; margin-bottom: 6px; font-weight: 500; color: var(--text); }
.form-group input, .form-group select, .form-group textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--border); border-radius: 4px; font-size: 14px; transition: border-color 0.2s; }
.form-group input:focus, .form-group select:focus, .form-group textarea:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.1); }
.form-row { display: flex; gap: 20px; }
.form-row .form-group { flex: 1; }
.btn { display: inline-block; padding: 10px 20px; border: none; border-radius: 4px; font-size: 14px; font-weight: 500; cursor: pointer; text-align: center; transition: background-color 0.2s; }
.btn-primary { background: var(--primary); color: white; }
.btn-primary:hover { background: var(--primary-dark); text-decoration: none; }
.btn-secondary { background: var(--secondary); color: white; }
.btn-secondary:hover { background: #475569; text-decoration: none; }
.btn-success { background: var(--success); color: white; }
.btn-danger { background: var(--danger); color: white; }
.btn-small { padding: 6px 12px; font-size: 12px; }
.btn-block { display: block; width: 100%; }
.btn + .btn { margin-left: 10px; }
.alert { padding: 12px 16px; border-radius: 4px; margin-bottom: 20px; }
.alert-error { background: #fef2f2; border: 1px solid #fecaca; color: var(--danger); }
.alert-success { background: #f0fdf4; border: 1px solid #bbf7d0; color: var(--success); }
.alert-info { background: #f0f9ff; border: 1px solid #bae6fd; color: var(--info); }
.main-header { display: flex; justify-content: space-between; align-items: center; padding: 12px 24px; background: var(--bg-white); border-bottom: 1px solid var(--border); box-shadow: var(--shadow); }
.main-header h1 { font-size: 18px; color: var(--text); }
.header-right { display: flex; align-items: center; gap: 16px; font-size: 13px; }
.fiscal-year { background: var(--primary); color: white; padding: 4px 12px; border-radius: 4px; }
.user-name { color: var(--text-light); }
.top-menu { padding: 24px; max-width: 1200px; margin: 0 auto; }
.menu-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(300px, 1fr)); gap: 24px; }
.menu-section { background: var(--bg-white); border-radius: 8px; box-shadow: var(--shadow); padding: 20px; }
.menu-section h2 { font-size: 16px; color: var(--text); margin-bottom: 16px; padding-bottom: 8px; border-bottom: 2px solid var(--primary); }
.menu-buttons { display: flex; flex-direction: column; gap: 8px; }
.menu-btn { display: block; padding: 12px 16px; background: var(--bg); border: 1px solid var(--border); border-radius: 4px; color: var(--text); font-size: 14px; transition: all 0.2s; }
.menu-btn:hover { background: var(--primary); color: white; border-color: var(--primary); text-decoration: none; }
.table-container { background: var(--bg-white); border-radius: 8px; box-shadow: var(--shadow); padding: 20px; margin-bottom: 24px; }
.table-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 16px; }
.table-header h2 { font-size: 18px; }
table { width: 100%; border-collapse: collapse; }
th, td { padding: 10px 12px; text-align: left; border-bottom: 1px solid var(--border); }
th { background: var(--bg); font-weight: 600; color: var(--text); }
tr:hover { background: #f8fafc; }
.text-right { text-align: right; }
.text-center { text-align: center; }
.search-form { background: var(--bg-white); border-radius: 8px; box-shadow: var(--shadow); padding: 20px; margin-bottom: 24px; }
.pagination { display: flex; justify-content: center; gap: 4px; margin-top: 20px; }
.pagination a, .pagination span { padding: 8px 12px; border: 1px solid var(--border); border-radius: 4px; font-size: 13px; }
.pagination a:hover { background: var(--primary); color: white; border-color: var(--primary); text-decoration: none; }
.pagination .current { background: var(--primary); color: white; border-color: var(--primary); }
.slip-form { background: var(--bg-white); border-radius: 8px; box-shadow: var(--shadow); padding: 24px; }
.slip-header { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1px solid var(--border); }
.detail-table { margin-top: 16px; }
.detail-table input, .detail-table select { width: 100%; padding: 6px 8px; border: 1px solid var(--border); border-radius: 3px; font-size: 13px; }
.detail-table th { background: #f1f5f9; font-size: 12px; white-space: nowrap; }
.detail-table td { padding: 4px; }
.slip-total { display: flex; justify-content: flex-end; gap: 24px; margin-top: 16px; padding-top: 16px; border-top: 2px solid var(--border); font-weight: 600; }
.slip-total .total-item { text-align: right; }
.slip-total .total-label { font-size: 12px; color: var(--text-light); }
.slip-total .total-value { font-size: 18px; }
@media (max-width: 768px) { .form-row { flex-direction: column; } .slip-header { grid-template-columns: 1fr; } .menu-grid { grid-template-columns: 1fr; } .header-right { flex-wrap: wrap; } }
